Focal Point
Alpha define field empty in WHERE clause

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/1211007481

September 08, 2006, 07:48 PM
dballest
Alpha define field empty in WHERE clause
Usage of defined field which is an alphanumeric field. Using this defined field in the where clause of the report, it passes empty value. If I set up the same value in the variable in dialog manager and use in the where clause of the report it works, does anybody face this kind of issue and how did you resolved it ?
In advance thanks for your reply !


Dev: WebFOCUS 7.6.10, Data Migrator 7.6.10
QA: WebFOCUS 7.6.10, Data Migrator 7.6.10
Prod: WebFOCUS 7.6.2, Data Migrator 7.6.8
Windows 2K3, Tomcat 5.5.17, IIS 6
Usage: HTML, PDF, Excel, Self-serve, BID and MRE
September 10, 2006, 11:37 PM
Piipster
Can you post your code?


ttfn, kp


Access to most releases from R52x, on multiple platforms.
September 11, 2006, 08:00 PM
dballest
Thanks for your reply !
Let me rephrase the question since now I found the problem here is passing parameters on Calling the Webservice and passes the defined field in the where clause doesn't work. It can only understand the Amper variables, so need to setup the date parameter in the string format before use in the where clause parameter.

Here is example
-SET &F='08/01/2006 06:00:00';
-SET &T='08/02/2006 06:00:00';

TABLE FILE ABC
PRINT
X1
X2
WHERE STRFROMDT = &F AND STRTODT = &T;
END ( IT's works)

My problem here now how to create the &F and &T.
I have &F and &T in the numeric format for e.g. 20060801 , how to concate and convert into string "08/01/2006 06:00:00". Tried the HCNVRT but didn't help. Let me know if you have idea.
Here is the example of code I tried ...
-SET &YR = EDIT(&DATEYYMD,'9999') ;
-SET &MO = EDIT(&DATEYYMD,'$$$$$99') ;
-SET &DD = EDIT(&DATEYYMD,'$$$$$$$$99') ;
-SET &TOX = &YR || &MO || &DD ;
-SET &FOX = AYMD(&TOX , -31, 'I8YYMD');
-SET &TOX1= DATECVT(&TOX, 'I6YMD', 'YYMD');
-SET &ALPHA_DATE1 = HCNVRT(&TOX, '(H17)', 17, 'A20');


Dev: WebFOCUS 7.6.10, Data Migrator 7.6.10
QA: WebFOCUS 7.6.10, Data Migrator 7.6.10
Prod: WebFOCUS 7.6.2, Data Migrator 7.6.8
Windows 2K3, Tomcat 5.5.17, IIS 6
Usage: HTML, PDF, Excel, Self-serve, BID and MRE
September 11, 2006, 11:33 PM
dhagen
Is this what you are looking for?
-SET &F = EDIT(&MDYY, '99/99/9999 ') | EDIT(HHMMSS('A8'),'99:$99:$99');  



"There is no limit to what you can achieve ... if you don’t care who gets the credit." Roger Abbott
September 12, 2006, 01:38 PM
dballest
quote:
-SET &F = EDIT(&MDYY, '99/99/9999 ') | EDIT(HHMMSS('A8'),'99:$99:$99');


Thanks for your reply !
This help me and able to solve the problem.


Dev: WebFOCUS 7.6.10, Data Migrator 7.6.10
QA: WebFOCUS 7.6.10, Data Migrator 7.6.10
Prod: WebFOCUS 7.6.2, Data Migrator 7.6.8
Windows 2K3, Tomcat 5.5.17, IIS 6
Usage: HTML, PDF, Excel, Self-serve, BID and MRE