As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.
Join the TIBCO Community TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.
From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
Request access to the private WebFOCUS User Group (login required) to network with fellow members.
Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.
I would like to use the values stored in an Oracle table against the WHERE statement in a TABLE FILE request.
The table (stored the WHERE values) named PARAMVAL has 2 fields as transid and FLD1VAL. This table is getting filled from a dot net screen and once read the webfocus has to delete the entries using a oracle package.
Suppose, it contains 3 records for transid EQ 1, as below.
1 ENGLAND 1 INDIA 1 AMERICA
-* passing from dot net -DEFAULT &TRANSID ='1'
I can issue a TABLE FILE PARAMVAL and do a DM READ to get the FLD1VAL if it was only one record.Also , I can not create a join between the XX and PARAMVAL because as per the design I can not provide a common key field to link.The transid field will be passed from dot net and once I read the value , I need to delete all the records pertaining the particular transid.
TABLE FILE XX PRINT * WHERE FLD1 EQ '&FLD1' END
Also , I know how it can be made using SQL pass through,
ENGINE SQLORA SET DEFAULT_CONNECTION ORATEST SQL SQLORA PREPARE SQLOUT FOR select * from xx where FLD1 in (select fld1val from PARAMVAL where transid ='&transid');
But as per the requirement,I am not supposed to use SQL passthrough.
Any suggestions on this?
Thanks and Regards, Johney Joseph.This message has been edited. Last edited by: Kerry,
Version 7.6.11 Webfocus installed in AIX 5.3, desktop PC: Windows-XP based Output: Excel, HTML, PDF
Generate the IN values and include them instead of using -READ
TABLE FILE CAR
SUM
COMPUTE INCOL/A20=''''||COUNTRY||''''||',';
BY SEATS NOPRINT
BY COUNTRY NOPRINT
WHERE SEATS EQ 2
ON TABLE SET HOLDLIST PRINTONLY
ON TABLE HOLD AS SELFILE FORMAT ALPHA
END
-RUN
TABLE FILE CAR
PRINT COUNTRY CAR MODEL
WHERE COUNTRY IN(
-INCLUDE SELFILE
'DUMMY SEL')
END
So what JG is suggesting is: -DEFAULT &FLD1 ='1' TABLE FILE XX SUM COMPUTE INCOL/A20=''''||FLD1VAL||''''||','; BY FLD1VAL NOPRINT WHERE FLD1 EQ '&FLD1' ON TABLE SET HOLDLIST PRINTONLY ON TABLE HOLD AS SELFILE FORMAT ALPHA END -RUN TABLE FILE filename verb fieldnames WHERE test_fieldname IN( -INCLUDE SELFILE 'DUMMY SEL') END
-------------------------------------------------------------------------------- prod: WF/AS 8.2.05; OmniGen; In FOCUS since 1991
Posts: 104 | Location: United Kingdom | Registered: February 07, 2008
JG - I tried the Hold and -INCLUDE method you prescribed above but had the following error:
ERROR: ERROR_MR_FEX_NOT_FOUND Can't create item object based on provided item key SELFILE.fex.
Does this technique depend on the environment configuration ? Our iWay server is on the mainframe and the client on a Windows server.
Thank you for posting. Best regards, Sandeep Mamidenna
------------------------------------------------------------------------------------------------- Blue Cross & Blue Shield of MS WF.76-10 on (WS2003 + WebSphere) / EDA on z/OS + DB2 + MS-SQL MRE, BID, Dev. Studio, Self-Service apps & a dash of fun !!
Posts: 218 | Location: Jackson, MS | Registered: October 31, 2006
------------------------------------------------------------------------------------------------- Blue Cross & Blue Shield of MS WF.76-10 on (WS2003 + WebSphere) / EDA on z/OS + DB2 + MS-SQL MRE, BID, Dev. Studio, Self-Service apps & a dash of fun !!
Posts: 218 | Location: Jackson, MS | Registered: October 31, 2006
TABLE FILE CAR SUM COMPUTE INCOL/A20=''''||COUNTRY||''''||','; BY SEATS NOPRINT BY COUNTRY NOPRINT WHERE SEATS EQ 2 ON TABLE SET HOLDLIST PRINTONLY ON TABLE HOLD AS SELFILE FORMAT ALPHA END -RUN TABLE FILE CAR PRINT COUNTRY CAR MODEL WHERE COUNTRY IN( -INCLUDE SELFILE 'DUMMY SEL') END
This code gives me the error,
0 NUMBER OF RECORDS IN TABLE= 5 LINES= 2 0 ERROR AT OR NEAR LINE 13 IN PROCEDURE ADHOCRQ FOCEXEC * (FOC263) EXTERNAL FUNCTION OR LOAD MODULE NOT FOUND: COUNTRY (FOC009) INCOMPLETE REQUEST STATEMENT
Doesn't need to be a .fex extension because the absolute path to the file is the working directory.
An INCLUDE must be named .fex if it resides in a location in the APP PATH however if the file is in the working edatemp directory or it's full path is specified it can be any extension.
The documentation on this is not very clear and contradictory.
You are right. Nonetheless, I have always found it is good programming practice.
BTW, I ran Johney's "quoted" code and it works fine, with and without the FILEDEF. So, either he is running something more than what is quoted or, maybe, in 7.1 he needs the FILEDEF...
Daniel In Focus since 1982 wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006
FILEDEF SELFILE DISK SELFILE.FEX
TABLE FILE CAR
SUM
COMPUTE INCOL/A20=''''||COUNTRY||''''||',';
BY SEATS NOPRINT
BY COUNTRY NOPRINT
WHERE SEATS EQ 2
ON TABLE SET HOLDLIST PRINTONLY
ON TABLE HOLD AS SELFILE FORMAT ALPHA
END
-RUN
0 NUMBER OF RECORDS IN TABLE= 5 LINES= 2
TABLE FILE CAR
PRINT COUNTRY CAR MODEL
WHERE COUNTRY IN(
-INCLUDE SELFILE
'ENGLAND',
'ITALY',
'DUMMY'
)
END
0 ERROR AT OR NEAR LINE 16 IN PROCEDURE ADHOCRQ FOCEXEC *
(FOC263) EXTERNAL FUNCTION OR LOAD MODULE NOT FOUND: COUNTRY
(FOC009) INCOMPLETE REQUEST STATEMENT
Thanks and Regards, Johney Joseph
Version 7.6.11 Webfocus installed in AIX 5.3, desktop PC: Windows-XP based Output: Excel, HTML, PDF
This line WHERE COUNTRY IN( try WHERE COUNTRY IN ( and make sure there are no tab characters only spaces I remember having several problems with tabs in 7.1
Thanks again GJ , your assumption was right. After the 'IN' I placed a space and it is working perfectly alright.
Thanks and Regards, Johney Joseph.
Version 7.6.11 Webfocus installed in AIX 5.3, desktop PC: Windows-XP based Output: Excel, HTML, PDF