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. Moving forward, myibi is our community platform to learn, share, and collaborate. We have the same Focal Point forum categories in myibi, so you can continue to have all new conversations there. If you need access to myibi, contact us at myibi@ibi.com and provide your corporate email address, company, and name.


Connect to myibi
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] missing on not working

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] missing on not working
 Login/Join
 
Silver Member
posted
Hello All,
I have a requirement to count number of header records and number of detail records.
my compute statement includes both header and detail records.
I am adding all detail records but when detail record is missing I want to add one.
why is it not working?
Below code is not adding one when details record is missing. It is adding one when I change my join to "UNIQUE".

JOIN
LEFT_OUTER HEADER.HEADER.MASTER_KEY IN HEADER TO MULTIPLE DETAILS.DETAILS.MASTER_KEY IN DETAILS
AS J0
END
TABLE FILE HEADER
SUM
CNT.HEADER.HEADER.MASTER_KEY AS 'HEADCNT'
COMPUTE DETCNT/I5 = IF DETAILS.DETAILS.MASTER_KEY IS MISSING THEN 1 ELSE CNT.DETAILS.DETAILS.MASTER_KEY; AS 'DETCNT';
BY REGION
END

Any help, I would appreciate.

Thanks,
SG.

This message has been edited. Last edited by: Kerry,


Webfocus 7.6.8
PDF,HTML & EXCEL
 
Posts: 32 | Location: memphis,tn | Registered: January 25, 2007Report This Post
Expert
posted Hide Post
It can't count something that is not there. Keep the multiple and put the results into a hold file. Report from the hold file and do your count there. That should give you the count you need.


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
Silver Member
posted Hide Post
Ginny,
thanks for your reply. I am not counting when detail record is missing. I want to add "1" when missing. May be I did not put it right.
why my "IF DETAILS.DETAILS.MASTER_KEY IS MISSING" not working.

Thanks,
SG.


Webfocus 7.6.8
PDF,HTML & EXCEL
 
Posts: 32 | Location: memphis,tn | Registered: January 25, 2007Report This Post
Silver Member
posted Hide Post
Nevermind. I figured it out. Used Inner join first to hold the data and Left outer join and unique for the report.
Looks like missing on will not work with join type mulitple.

Thanks,
SG.


Webfocus 7.6.8
PDF,HTML & EXCEL
 
Posts: 32 | Location: memphis,tn | Registered: January 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     [SOLVED] missing on not working

Copyright © 1996-2020 Information Builders