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     [SOLVED] FIND DIFFERENCE ACROSS USING OVER

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] FIND DIFFERENCE ACROSS USING OVER
 Login/Join
 
Gold member
posted
Thanks GamP. This helped me get a start. Thought it might have something to do with using LAST command, but have not used it that much.
Instead of just COMPUTE DIFF1 = LAST CUST_Y_PCT - CUST_Y_PCT; OVER I added:

IF CHNL_TYP EQ 'X' THEN LAST CUST_Y_PCT - CUST_Y_PCT ELSE 0; Otherwise, there was a calculation for the first ACROSS value which is zero - whatever value. This way, there was only a value displayed for the difference between the two across columns. But, not only did I not want calculated values outside of the values between across columns, I did not want to show anything. So...

I changed from ACROSS CHNL_TYP to BY, removed OVER's and HELD it. Then I built another report summed data using ACROSS and OVER's. This way, I was able to get that DIFF displayed in a footer.

Not sure if there is a simpler way, but this works the way I want.

thanks again, could not have done it without the advice.

Bob

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


WF (App Studio) 8.2.01m / Windows
Mainframe FOCUS 8
 
Posts: 93 | Registered: February 20, 2008Report This Post
Virtuoso
posted Hide Post
Maybe siomething like this is what you're looking for?
TABLE FILE CUSTOMER
SUM   CNT.CUST OVER
      CUST_Y OVER
      COMPUTE CUST_Y_PCT/D12.2%= ( CUST_Y / CNT.CUST ) * 100; OVER
	  COMPUTE DIFF1 = LAST CUST_Y_PCT - CUST_Y_PCT; OVER
      CUST_N OVER 
      COMPUTE CUST_N_PCT/D12.2%= ( CUST_N / CNT.CUST ) * 100; OVER
	  COMPUTE DIFF2 = LAST CUST_N_PCT - CUST_N_PCT;
ACROSS CHNL_TYP
ACROSS-TOTAL AS 'TOTALS' AND RECOMPUTE
END


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     [SOLVED] FIND DIFFERENCE ACROSS USING OVER

Copyright © 1996-2020 Information Builders