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     Allocating same MFD file to many Focus files

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Allocating same MFD file to many Focus files
 Login/Join
 
Silver Member
posted
I am using Focus in Mainframes.
I want to allocate a same MFD file to five focus files and join them all to a single input file. One way which i used is to allocate the MFD file to one focus file and then use it in program and then free it. Then again allocate it to next and repeat the code. This works but it requires code repetition.
Is there any other efficient way to do it?


FOCUS 7.1.1/ MF(OS/390)
 
Posts: 40 | Location: Chennai, India | Registered: January 31, 2007Report This Post
Virtuoso
posted Hide Post
Manash

If these are FOCUS data files, then they can be concatenated in the USE command
USE
CAR1 AS CAR
CAR2 AS CAR
CAR3 AS CAR
END
JOIN COUNTRY IN CAR TO COUNTRY IN otherfile AS J1.
TABLE FILE CAR
.
.


This is fine if you want to JOIN from this structure. However you cannot JOIN directly to it from another file.


Alan.
WF 7.705/8.007
 
Posts: 1451 | Location: Portugal | Registered: February 07, 2007Report This Post
Expert
posted Hide Post
In a CLIST:

ALLOC F(CAR) DSNAME
('&SYSUID.CAR1.FOC' - OR +
'&SYSUID.CAR2.FOC' - OR +
'&SYSUID.CAR3.FOC') SHR REUSE

In JCL:

//CAR DD DSN=&SYSUID.CAR1.FOC,DISP=SHR
// DD DSN=&SYSUID.CAR2.FOC,DISP=SHR
// DD DSN=&SYSUID.CAR3.FOC,DISP=SHR


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Master
posted Hide Post
Tom

Your above technique will work with flat files but not with focus databases.

focus needs to find the fdt in the first page of the physical file and so will only be able to find it for the first in the concatenated list. The fdt's for the 2nd and 3rd files will be embedded somewhere in the concatenated file and never accessed.

This is why you use Alan's syntax where is file is picked out separately by a use command

John



Server: WF 7.6.2 ( BID/Rcaster) Platform: W2003Server/IIS6/Tomcat/SQL Server repository Adapters: SQL Server 2000/Oracle 9.2
Desktop: Dev Studio 765/XP/Office 2003 Applications: IFS/Jobscope/Maximo
 
Posts: 888 | Location: Airstrip One | Registered: October 06, 2006Report This Post
Silver Member
posted Hide Post
I have not used USE command till now.Can anyone please elobrate how to use USE command in this case. My MFD file is 'country'.
And i have five FOCUS files -
myname.us1.focus
myname.us2.focus
myname.us3.focus
myname.us4.focus
myname.us5.focus
I need allocate the same MFD (i.e. 'country') to these five files and need to join the input file to these five files in my program.


FOCUS 7.1.1/ MF(OS/390)
 
Posts: 40 | Location: Chennai, India | Registered: January 31, 2007Report This Post
Expert
posted Hide Post
Manash,

If you had your signature updated with your release and platform then someone might be able to give you specifics.

In this instance it would be a good idea to look at the documentation first and understand the command in your environment.

Click on the "Search the Technical Documentatin Library" link above and search on "USE" or "Identifying a FOCUS Data Source".

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Expert
posted Hide Post
John,

You are correct, I had flat files on my mind. FOCUS DB's still need to be allocated, though, for each dataset...


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Expert
posted Hide Post
... and this is where the signature piece comes in - knowing what platform someone is on when they ask a question.

Tom is giving an answer from a Z/OS platform point of view whereas on windows it would be different.

Help us to help you by changing your signature to include platform and release.

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Silver Member
posted Hide Post
Sorry guys!
I have updated my signature now.


FOCUS 7.1.1/ MF(OS/390)
 
Posts: 40 | Location: Chennai, India | Registered: January 31, 2007Report This Post
Silver Member
posted Hide Post
I tried the above case using 'USE' command but I am getting the following error

(FOC1850) MISMATCH IN NUMBER OF FILES IN COMPONENT OF CONCATENATION

The "USE" command is running fine in this case but when i am joining the input file to 'Country' after the 'USE' command, I am getting the above error.

Can anyone please tell me what could be the possible reason for this error?
In the above case -
the MFD 'Country' has a single cross reference file 'State'.


FOCUS 7.1.1/ MF(OS/390)
 
Posts: 40 | Location: Chennai, India | Registered: January 31, 2007Report This Post
Master
posted Hide Post
As Alan states above,

quote:
This is fine if you want to JOIN from this structure. However you cannot JOIN directly to it from another file.


In FOCUS since 1985. Prod WF 8.0.08 (z90/Suse Linux) DB (Oracle 11g), Self Serv, Report Caster, WebServer Intel/Linux.
 
Posts: 975 | Location: Oklahoma City | Registered: October 27, 2006Report This Post
Silver Member
posted Hide Post
I need to JOIN TO this structure not JOIN FROM this structure. Any way to do it?


FOCUS 7.1.1/ MF(OS/390)
 
Posts: 40 | Location: Chennai, India | Registered: January 31, 2007Report This Post
Master
posted Hide Post
Manash

MATCH FILE is a merge based JOIN facility that allows you to perform UNIQUE JOINs. (JOIN to MULTIPLE|ALL is not supported)

Because it is merge based it also allows FULL OUTER joins (not available any where else). However being merge based means that it may not be as efficient as index based joins.

BUT ITS GREATEST ADVANTAGE IS THAT IT PLACES NO RESTRICTIONS ON THE DATA SOURCES TO BE JOINED. THEY CAN BE FLAT FILES OR UNINDEXED DATA OR DATA THAT IS A CONCATENATION FROM MANY INDIVIDUAL DATABASES.

To convert

JOIN [INNER|LEFT_OUTER] fld1a [AND fld1b]... IN table1 TO UNIQUE fld2a [AND fld2b]...IN table2
TABLE FILE table1
{WebFOCUS request}
END

Here is the equivalent MATCH based JOIN.

MATCH FILE table2
SUM
{list of fields required from table2}
BY fld2a
[BY fld2b]...
RUN
FILE table1
PRINT
{list of fields required from table1}
BY fld1a AS fld2a
[BY fld1b AS fld2b]...
AFTER MATCH HOLD AS holdfile [NEW|OLD AND NEW|OLD OR NEW]
END
-RUN
TABLE FILE holdfile
{WebFOCUS request}
END

The MATCH options correspond to the JOIN options.

NEW = LEFT_OUTER
OLD-AND-NEW = INNER
OLD-OR-NEW = FULL_OUTER - Not supported under wf JOIN syntax - the only way to accomplish is via MATCH FILE.

This message has been edited. Last edited by: hammo1j,



Server: WF 7.6.2 ( BID/Rcaster) Platform: W2003Server/IIS6/Tomcat/SQL Server repository Adapters: SQL Server 2000/Oracle 9.2
Desktop: Dev Studio 765/XP/Office 2003 Applications: IFS/Jobscope/Maximo
 
Posts: 888 | Location: Airstrip One | Registered: October 06, 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     Allocating same MFD file to many Focus files

Copyright © 1996-2020 Information Builders