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]displaying multiple columns under single temporary heading

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED]displaying multiple columns under single temporary heading
 Login/Join
 
Member
posted
displaying sales, retail cost and dealer cost for each country and car under the column name “cost”, first the sales should be displayed for each country and car followed by the retail cost and dealer cost.

This message has been edited. Last edited by: Darshan Patil,
 
Posts: 10 | Location: Bangalore | Registered: July 31, 2018Report This Post
Virtuoso
posted Hide Post
Of course you could use OVER, but it seems to me this is not your aim. So here is a suggestion, using an "alternate master":
  
-SET &ECHO=ALL;
-* File darshan01.fex
DEFINE FILE CAR
-* Use same format at rcost & dcost
DSALES/D7=SALES;
END
-RUN
-* Extract sales, rcost and dcost. These fields will be placed on the same record for each country/car pair
TABLE FILE CAR
SUM DSALES DCOST RCOST
BY COUNTRY
BY CAR
ON TABLE HOLD AS DARSHAN FORMAT ALPHA
END
-RUN
-* Create an alternate master for the extract. The hierarchy maps sales, rcost and dcost to separate records
EX -LINES 8 EDAPUT MASTER,DARSHAN,C,MEM
 FILENAME=DARSHAN , SUFFIX=FIX
 SEGMENT=DARSHAN, SEGTYPE=S0
 FIELDNAME=COUNTRY, ALIAS=E01, USAGE=A10, ACTUAL=A10, $
 FIELDNAME=CAR, ALIAS=E02, USAGE=A16, ACTUAL=A16, $
 SEGMENT=COST, PARENT=DARSHAN, OCCURS=VARIABLE
 FIELDNAME=COST, ALIAS=E03, USAGE=D7, ACTUAL=A07, $
 FIELDNAME=ORD, ALIAS=ORDER, USAGE=I2, ACTUAL=I4, $
-RUN
-* Et voila!
TABLE FILE DARSHAN
PRINT COST
BY COUNTRY
BY CAR
BY ORD NOPRINT
END
-RUN
-* If you want to have a label for each "cost", you can use a DEFINE:
DEFINE FILE DARSHAN
CNAME/A5=DECODE ORD(1 SALES 2 DCOST 3 RCOST);
END
TABLE FILE DARSHAN
PRINT COST
BY COUNTRY
BY CAR
BY ORD NOPRINT
BY CNAME 
END
-RUN


Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF

 
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006Report This Post
Expert
posted Hide Post
Something like this, OVER:
TABLE FILE CAR
SUM SALES/D12C AS COST' OVER RCOST/D12C OVER DCOST/D12C
BY COUNTRY BY CAR
END
-* Like Danny said: If you want to have a label for each "cost", you can use a DEFINE.
 
Posts: 3132 | Location: Tennessee, Nashville area | Registered: February 23, 2005Report This Post
Member
posted Hide Post
Thanks Danny and Doug for your suggestions
both of them worked.
 
Posts: 10 | Location: Bangalore | Registered: July 31, 2018Report 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]displaying multiple columns under single temporary heading

Copyright © 1996-2020 Information Builders