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     How to combine results of two reports

Read-Only Read-Only Topic
Go
Search
Notify
Tools
How to combine results of two reports
 Login/Join
 
Member
posted
I have a report that presents data for one year. I can of course change this report to process for other years. Here's my question. I'm thinking of running this report for one particular year, then copying that code to the bottom of the FOCEXEC and running that part for another year; after that, I would like to create one report that reflects what the two previous reports showed.

How might I go about doing this?
 
Posts: 9 | Registered: April 02, 2007Report This Post
Virtuoso
posted Hide Post
Do a search on Compound Reports.


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
 
Posts: 1903 | Location: San Antonio | Registered: February 28, 2005Report This Post
Platinum Member
posted Hide Post
You can also try to run the report for both years and do a page break for each year.
Just a suggestion.

Good luck

et


FOCUS 7.6 MVS PDF,HTML,EXCEL
 
Posts: 115 | Location: Chicago, IL | Registered: May 28, 2004Report This Post
Expert
posted Hide Post
are you in PDF or HTML or EXCEL
and please update your signature so we know what version/platform you're on.

are you familiar with the concept of LOOPs?
you'll set your year as an &variable
and execute your single set of code 2 times,
here is a simple example
-SET &YEAR = 2006 ;
-toploop
TABLE FILE ...
IF YEAR IS &YEAR
ON TABLE HOLD AS MYTAB&KOUNTER FORMAT HTMTABLE
END
-RUN
-IF &YEAR IS 2007 GOTO done;
-SET &YEAR = 2007 ;
-GOTO toploop;
-done

-HTMLFORM BEGIN
!IBI.FIL.MYTAB0;
!IBI.FIL.MYTAB1;
-HTMLFORM END

For PDF or EXCEL , you'll need to do what Prarie says, go read up on Compound Reports.
or..do what ET says, alot simpler!




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
I'm not sure what you are wanting to accomplish. If you want your report to be:
Sales for 2007
England $$$$
Italy $$$$
Sales for 2006
England $$$$
Italy $$$$

then using a compound report or a loop will work. Simply add ON TABLE SET COMPOUND OPEN to the first report and ON TABLE SET COMPOUND CLOSE to the last.

However, if what you are wanting is:
Sales for 2007 Sales for 2006
Endland $$$$ $$$$
Italy $$$$ $$$$

then if the data for both years is in the same file, extract both years and use ACROSS sales year. If the data is in different files, extract each year's data and use MATCH to put the files together.


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
 
Posts: 755 | Location: TX | Registered: September 25, 2007Report This Post
Virtuoso
posted Hide Post
Of course it is also quite possible that you need to create one report out of two different files. If that is the case, you may be able to do something like this:

APP FI TEST DISK GamP/TEST.FTM 

TABLE FILE CAR
PRINT CAR BODY MODEL SEATS SALES
BY COUNTRY
IF COUNTRY EQ 'ENGLAND'
ON TABLE HOLD FORMAT ALPHA AS TEST
END
APP FI TEST DISK GamP/TEST.FTM (APPEND

TABLE FILE CAR
PRINT CAR BODY MODEL SEATS SALES
BY COUNTRY
IF COUNTRY EQ 'ITALY'
ON TABLE HOLD FORMAT ALPHA AS TEST
END

TABLE FILE TEST PRINT *
END

As long as the output of the two different reports is exactly the same in terms of lengths of the columns, this will work, also allowing for a change of sort fields and such.

Hope this helps.
GamP


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report 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     How to combine results of two reports

Copyright © 1996-2020 Information Builders