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.



Read-Only Read-Only Topic
Go
Search
Notify
Tools
Merging Hold Files.
 Login/Join
 
Platinum Member
posted
If the structure of two hold files are same then how to proceed with merging its contains.

Holdfile1
Country Count
India 1

Holdfile2
Country Count
India 4

Holdfile3 (Merge of above two)
Country Count
India 5

If anyone can provide with any clone pgms, then it will be gr8.

thanks
sambit


WF Server: 7.1.4 on Z/OS and Linux, ReportCaster
Data: DB2, DB2/UDB, Adabas, SQL Server, Oracle Output: HTML,PDF,Excel2K
WF Client: Servlet, CGI
 
Posts: 133 | Registered: May 12, 2007Report This Post
Expert
posted Hide Post
Sambit,
its pretty easy.
look up the MORE command in your manual, or do a search on this site.
TABLE FILE H1
PRINT *
ON TABLE HOLD AS H3
MORE
FILE H2
END
-S.




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
Master
posted Hide Post
Susannah, is right it is that easy. You do not have to use hold files to use the MORE command also, You might be able to use the actual tables it the fieldname are the same.




Scott

 
Posts: 865 | Registered: May 24, 2004Report This Post
Platinum Member
posted Hide Post
Hi all,
i am also ahving the same problem like i merged my 5 hold files by using FILE DEF APPEND
HERE THE PROBLEM IS the values of the first hold file are changine if append.

is there any work around for this.
please give me a difference between USE, FILEDEF APPEND and MORE.

Thanks,


Thanks,
Kalyan.S
------------------------------------
WebFOCUS 7.1.4, Win XP SP2,
Oracle8i.
------------------------------------
 
Posts: 155 | Location: Bangalore. | Registered: January 24, 2006Report This Post
Virtuoso
posted Hide Post
Kalyan

USE.
Is the command to point to a FOCUS datafile, SUFFIX=FOC or SUFFIX=XFOCUS only. It can be used to locate the data file, have an alternate master file descriptions, concatenate data files or use the FDS, e.g:
USE
path/file.foc as otherfile
END
USE
path/file.foc
END
USE
file.foc on FOCSU01
END
USE
file1.foc as filea
file2.foc as filea
END

MORE.
Allows 2 or more (different or similar) data sources to be concatenated together with a main request and following sub-requests. Data is retrieved from all data sources, sorted and then output as specified in the main request, e.g:
TABLE FILE filename1
PRINT field1
field2
BY field3
WHERE field3 EQ value;
ON TABLE PCHOLD FORMAT HTML
MORE
FILE filename2
WHERE field3 EQ value;
END


FILEDEF...(APPEND
Allows disparate data to be held or saved to disk from multiple requests using the FILEDEF ddname. Data is added to the file for each request. To create a new file, issue a FILEDEF without append before the first request and then issue a FILEDEF with APEND for subsequent requests. Another request needs to be run against this data to get user output, e.g:
FILEDEF FOO DISK PATH/FOO.FTM
TABLE FILE file1
PRINT field1
BY field2
ON TABLE HOLD AS FOO
END
FILEDEF FOO DISK PATH/FOO.FTM (APPEND
TABLE FILE file2
PRINT field3
BY field4
ON TABLE HOLD AS FOO
END
TABLE FILE FOO
PRINT
.
.
END

If you are having problems can you explain in more detail what is happening when you say the values in first HOLD file are changing.


Alan.
WF 7.705/8.007
 
Posts: 1451 | Location: Portugal | Registered: February 07, 2007Report This Post
Platinum Member
posted Hide Post
Hi Alan,
i merged ALPHA format file also by s]using USE.
i hope there is no format constraint.
please check and lket me know.

my problem is i ahve columns like A,B and c
and the c is A-B. here if i append by usingFILEDEF the values of the C are changing
ionstead of nEGATIVE vALUES IT IS SHOWING pOSTIVE AND SOMETIMES THE VALUES ARE ALSO CHANGING.

can you please checkout this.

Thanks,


Thanks,
Kalyan.S
------------------------------------
WebFOCUS 7.1.4, Win XP SP2,
Oracle8i.
------------------------------------
 
Posts: 155 | Location: Bangalore. | Registered: January 24, 2006Report This Post
Virtuoso
posted Hide Post
Kalyan

What you are saying makes very little sense.

The USE is for extracting from FOCUS datafiles, usually .FOC, FILEDEF is for flat files, often as a result of a TABLE request output.

The request to merge data sources with FILEDEF...(APPEND is very simple. The table request appends the data from a request to the end of an existing file. Without the APPEND, a new file is created.

If you follow the logic through, you should get:
USE
myPath/CAR.FOC
END
FILEDEF MYFILE DISK myPath/FILE1.FTM
TABLE FILE CAR
PRINT RCOST DCOST AND COMPUTE
DIFF/I6 = DCOST-RCOST;
BY COUNTRY
BY CAR
IF COUNTRY EQ ENGLAND
ON TABLE HOLD AS FILE1 FORMAT ALPHA
END
-* file FILE1 now created from new, so next request append to it.
FILEDEF MYFILE DISK myPath/FILE1.FTM (APPEND
TABLE FILE CAR
PRINT RCOST DCOST AND COMPUTE
DIFF/I6 = DCOST-RCOST;
BY COUNTRY
BY CAR
IF COUNTRY EQ ITALY
ON TABLE HOLD AS FILE1 FORMAT ALPHA
END

So now you should have a file, FILE1.FTM containing data from ENGLAND and ITALY. The second request for ITALY cannot touch the data already in the file for ENGLAND. You can now TABLE FILE1.


Alan.
WF 7.705/8.007
 
Posts: 1451 | Location: Portugal | Registered: February 07, 2007Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic


Copyright © 1996-2020 Information Builders