Focal Point Banner


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.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     joining db2 file to wf holdfile?

Read-Only Read-Only Topic
Go
Search
Notify
Tools
joining db2 file to wf holdfile?
 Login/Join
 
Platinum Member
posted
I'm using SQL to download data from our DB2/AS400 connection and I was wondering if it was at all possible to use either hold or save files as part of those SQL queries. The only reason I ask is because some of our sales history files contain millions of records and this would help filter that amount greatly.


dev: WF 7.6.5 w/IIS + Tomcat

prod: WF 7.6.5 w/IIS + Tomcat
 
Posts: 153 | Location: Chicago, IL | Registered: February 24, 2006Report This Post
Platinum Member
posted Hide Post
Yes it is possible. Joining a hold file to a big DB2 table is tricky. The way iWay/WebFOCUS works in this situation is it will send as much of the query it can DB2 bring back the data and then do the join in the reporting server. So if you have good filtering criteria that restricts the data to small subset it works great, if not you are in trouble.


WF7.1.4 Prod/Test, MRE, self serve, DM
 
Posts: 176 | Location: Desplaines | Registered: August 05, 2004Report This Post
Platinum Member
posted Hide Post
Well my question is how do I go about writing that SQL statement. What I have goes something like:

SQL DB2 PREPARE SQLOUT FOR
SELECT FIELD1, FIELD2, FIELD3
FROM LIBRARY.FILE JOIN HOLD
ON LIBRARY.FILE.FIELD1 = HOLD.KEYFIELD
WHERE LIBRARY.FIELD.FIELD2 = 'CRITERIA';
END

TABLEF FILE SQLOUT
PRINT *
END

And the error it gives me has something to do with not knowing which library HOLD belongs to....


dev: WF 7.6.5 w/IIS + Tomcat

prod: WF 7.6.5 w/IIS + Tomcat
 
Posts: 153 | Location: Chicago, IL | Registered: February 24, 2006Report This Post
Platinum Member
posted Hide Post
Eric,

I am not able to provide a code sample, but we do something like this;

Use the READ command to dynamically build a SQL IN statement from your HOLD file. It involves setting up a counter, looping through your HOLD file using DIALOGUE MANAGER and -READ, and using the resulting IN statement in your WHERE condition rather than trying to JOIN to a file SQL doesn't know about.

Hope this helps,

Kevin


WF 7.6.10 / WIN-AIX
 
Posts: 141 | Location: Denver, CO | Registered: December 09, 2005Report This Post
Platinum Member
posted Hide Post
Thats not a bad idea, I will give that a try, Thanks.


dev: WF 7.6.5 w/IIS + Tomcat

prod: WF 7.6.5 w/IIS + Tomcat
 
Posts: 153 | Location: Chicago, IL | Registered: February 24, 2006Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     joining db2 file to wf holdfile?

Copyright © 1996-2020 Information Builders