Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Print two AS names for a column
Go
New
Search
Notify
Tools
Reply
  
[SOLVED] Print two AS names for a column
 Login/Join
 
Member
posted
I have a requirement to generate a report with column of data which needs to display in two cloumns :

Hold File Output:

CUSTOMER Level SENDER REQUESTS
319 1 AA 32
319 2 PH 12
319 3 AA 9
319 4 PH 5


Output to be printed:

CUSTOMER SENDER AA REQUESTS AA RESPONSES
319 1 32 25
319 3 9 4

CUSTOMER SENDER PH REQUESTS PH RESPONSES
319 2 12 22
319 4 5 7

TABLE FILE HLD_FINAL
PRINT
CUSTOMER_ID AS 'Customer'
-IF &SENDER.&I EQ 'PH' THEN GOTO PH_REP ELSE GOTO AA_REP;
-PH_REP
REQUESTS/D12C AS 'PH Reuests Received'
-GOTO END_REP;
-AA_REP
REQUESTS/D12C AS 'Requests Received'
-END_REP
ON CUSTOMER PAGE-BREAK
END

Tried with read file using loop.. but unable to print. Can you please suggest to print specific column AS name.
Thanks,
Vijay

This message has been edited. Last edited by: FP Mod Chuck,
 
Posts: 9 | Registered: March 23, 2018Reply With QuoteReport This Post
Virtuoso
posted Hide Post
Not sure why you mean my able to print, are you not getting any output. Try adding a -RUN after END.
 
Posts: 1903 | Location: San Antonio | Registered: February 28, 2005Reply With QuoteReport This Post
Guru
posted Hide Post
Do you want to have 2 outputs, or everything combined in one grid?

If combined, try using Subhead on SENDER, I think togheter with HEADALIGN for the titles you can can get it in one grid.


Test: WF 8.2
Prod: WF 8.2
DB: Progress, REST, IBM UniVerse/UniData, SQLServer, MySQL, PostgreSQL, Oracle, Greenplum, Athena.
 
Posts: 381 | Location: Europe | Registered: February 05, 2007Reply With QuoteReport This Post
Guru
posted Hide Post
You can use a DEFINE

[/CODE]
DEFINE FILE HLD_FINAL
AA_REQUESTS/D12C=IF SENDER EQ 'AA' THEN REQUESTS ELSE 0;
PH_REQUESTS/D12C=IF SENDER EQ 'PH' THEN REQUESTS ELSE 0;
END
TABLE FILE HLD_FINAL
PRINT
CUSTOMER_ID AS 'Customer'
AA_REQUESTS AS 'Requests Received'
PH_REQUESTS AS 'PH Requests Received'
END
[/CODE]

Fernando


Prod WF 8.1.04, QA WF 8.2.03, Dev WF 8.2.03
 
Posts: 261 | Registered: October 10, 2006Reply With QuoteReport This Post
Member
posted Hide Post
The output is with page break at sender level and at customer level and out of 4 rows from the final hold file the two column names should differ(AA Requests, PH Requests) for request for requests and responses which will be differentiated by Sender(AA/PH) column.

CUSTOMER LEVEL AA_REQUESTS AA_RESPONSES
319 1 32 25
319 3 9 4

CUSTOMER LEVEL PH_REQUESTS PH_RESPONSES
319 2 12 22
319 4 5 7


WebFOCUS 8

Windows, All Outputs
 
Posts: 9 | Registered: March 23, 2018Reply With QuoteReport This Post
Expert
posted Hide Post
Please refer to This Post as it was answered there.
 
Posts: 2967 | Location: Middle Tennessee [8204M Gen48 in Test&Prod] | Registered: February 23, 2005Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Print two AS names for a column

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.