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     [CLOSED] Print data in holdfiles in specific order/in multiple lines in excel format

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Print data in holdfiles in specific order/in multiple lines in excel format
 Login/Join
 
Member
posted
Hi All,

Is it possible to print two hold files one after the other for summary and detail format in Excel format. able to get like Output holdfiles one hold file followed by next hold file.

Below are the hold files
TABLE FILE CAR
SUM RCOST
DCOST
BY COUNTRY
HEADING
"Summary at Country Level"
FOOTING
""
ON TABLE PCHOLD FORMAT EXL2K OPEN NOBREAK
END
TABLE FILE CAR
SUM RCOST
DCOST
BY COUNTRY
BY CAR
HEADING
"Summary at Country and Car Level"
FOOTING
""
ON TABLE PCHOLD FORMAT EXL2K NOBREAK
END
TABLE FILE CAR
SUM RCOST
DCOST
BY COUNTRY
BY CAR
BY MODEL
HEADING
"Detail at Model Level"
FOOTING
""
ON TABLE PCHOLD FORMAT EXL2K CLOSE
END

The output needs to be like

COUNTRY RETAIL_COST DEALER_COST
ENGLAND 45,319 37,853

COUNTRY CAR RETAIL_COST DEALER_COST
ENGLAND JAGUAR 22,369 18,621
JENSEN 17,850 14,940
TRIUMPH 5,100 4,292

COUNTRY CAR MODEL RETAIL_COST DEALER_COST
ENGLAND JAGUAR V12XKE AUTO 8,878 7,427
XJ12L AUTO 13,491 11,194
JENSEN INTERCEPTOR III 17,850 14,940
TRIUMPH TR7 5,100 4,292

COUNTRY RETAIL_COST DEALER_COST
FRANCE 5,610 4,631

COUNTRY CAR RETAIL_COST DEALER_COST
FRANCE PEUGEOT 5,610 4,631

COUNTRY CAR MODEL RETAIL_COST DEALER_COST
FRANCE PEUGEOT 504 4 DOOR 5,610 4,631

....
In the excel the output displays like summary row for one record followed by details and second summary row followed by details having page break by country.

Any suggestions.. Please update

Thank You!

This message has been edited. Last edited by: FP Mod Chuck,


WebFOCUS 8

Windows, All Outputs
 
Posts: 9 | Registered: March 23, 2018Report This Post
Silver Member
posted Hide Post
There may be a better answer but when I've needed to do this kind of thing I've wrapped it up in a loop or two allowing me to repeat the extract or output code a number of times while feeding in a parameter from a generated hold file. So along the lines of:
TABLE FILE CAR
BY COUNTRY
ON TABLE NOTOTAL
ON TABLE HOLD AS CLIST
END
-RUN
-SET &CCNT = &LINES ;

-REPEAT :ENDREPEAT2 FOR &I FROM 1 TO &CCNT
-READFILE CLIST
-RUN

.
.
.
your extract code +
Where COUNTRY EQ ‘&COUNTRY’ ;
.
.
.

-:ENDREPEAT2
-RUN


7.7.05 Windows.
 
Posts: 39 | Location: UK | Registered: July 11, 2012Report This Post
Virtuoso
posted Hide Post
Basically, what you are requesting is subtotals on each BY field where the subtotal is above the detailed line
Does something such as this may suits your need ?
TABLE FILE CAR
SUM RETAIL_COST
    DEALER_COST
BY COUNTRY
ON COUNTRY RECOMPUTE AS 'Country Total'
BY CAR
ON CAR     RECOMPUTE AS 'Car Total'
BY MODEL
ON MODEL   RECOMPUTE AS 'Model Total'
ON TABLE PCHOLD FORMAT XLSX
-* To create a "page-break" (new tab) in Excel
ON TABLE SET COMPOUND BYTOC
-* To have the subtotal placed above the detailed data
ON TABLE SET SUBTOTALS ABOVE
ON TABLE SET PAGE-NUM NOLEAD
-* To make all BY fields displayed on each line
ON TABLE SET BYDISPLAY ON
-* To avoid the display of the Grand-Total
ON TABLE NOTOTAL
ON TABLE SET LINES 999999
ON TABLE SET HTMLEMBEDIMG ON
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
     INCLUDE = IBFS:/EDA/EDASERVE/_EDAHOME/ETC/endeflt.sty,
$
ENDSTYLE
END
-RUN


WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF
In Focus since 2007
 
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013Report This Post
Member
posted Hide Post
Thank You Martin. Can we display the column names separately for each subtotal fields.


WebFOCUS 8

Windows, All Outputs
 
Posts: 9 | Registered: March 23, 2018Report This Post
Virtuoso
posted Hide Post
quote:
Can we display the column names separately for each subtotal fields.

What do you mean by the above ?
Can you illustrate with a sample output ?


WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF
In Focus since 2007
 
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013Report 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     [CLOSED] Print data in holdfiles in specific order/in multiple lines in excel format

Copyright © 1996-2020 Information Builders