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     Totalling across values.

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Totalling across values.
 Login/Join
 
Member
posted
I have a report that is laid out with
Sales Rep, Division, Store,
and then an across of Dept (which has 4 unique depts).
for each store I have 2 unique rows, 'CP' and 'YTD'. I need a territory summary after each Sales rep, that will total for 'CP' and 'YTD' for each of the 4 depts. I can't figure it out. And BI support has yet to get back to me. Any geniuses out there that could help me?


WF 7.1.6 Platform Windows; Databases Informix, msSQL2000, msSQL2005, Unisys DMSII
Output HTML, EXCEL, PDF
 
Posts: 11 | Location: Salt Lake City, Utah | Registered: May 15, 2006Report This Post
Platinum Member
posted Hide Post
Francis had a very good example a while back that might help...

https://forums.informationbuilders.com/eve/forums/a/tpc/...311078331#3311078331


------------------------------------------------------------------------
PROD: WebFOCUS 7.6.2 on Unix AIX/Tomcat/Servlet Mode
TEST: WebFOCUS 7.6.2 on Unix AIX/Tomcat/Servlet Mode
 
Posts: 210 | Location: Ottawa | Registered: November 03, 2005Report This Post
Platinum Member
posted Hide Post
You'll have to give a bit more info than that. Are the rows for CP and YTD done with an OVER or are they values that you can report from? I tried playing with the GGSALES table and found that I hit a roadblock when trying to come up with something.

If it's an OVER, then subtotal may do what you want.

Ken


Prod - WF 7.6.4 Unix/Solaris - Self-Service, BI Dashboard, MRE
Dev - WF 7.6.4 Unix/Solaris - Self-Service, BI Dashboard, MRE
Databases: Oracle 10g, SQL Server 2000, DB2.
 
Posts: 177 | Location: Calgary, Alberta, Canada | Registered: April 25, 2005Report This Post
Expert
posted Hide Post
Ken has hit upon a solution for you and that is to use OVER on CP and YTD instead of sorting by them (if that is what you are doing?).

For an example we first have to get some data to mimic what I think yours might look like, and to do that I will use the McGyver method and then join to GGSALES as it has similar data to what you describe -
APP FI MCGYVER DISK MCGYVER.MAS (LRECL 80
-RUN
-WRITE MCGYVER
-WRITE MCGYVER FILE=MCGYVER,SUFFIX=FOC
-WRITE MCGYVER SEGNAME=SEG1
-WRITE MCGYVER FIELD=MCGYVER_KEY,   ,A1   ,A1   ,FIELDTYPE=I, $
-WRITE MCGYVER FIELD=SUM_TYPE,  ,A3   ,A3   ,$
-RUN

CREATE FILE MCGYVER
MODIFY FILE MCGYVER
FIXFORM MCGYVER_KEY/A1 SUM_TYPE/A3
DATA
 CP 
 YTD
END
-RUN

JOIN MCGYVER_KEY WITH REGION IN GGSALES TO MULTIPLE MCGYVER_KEY IN MCGYVER AS J1


DEFINE FILE GGSALES
  MCGYVER_KEY/A1 WITH REGION = ' ';
  CUR_PERIOD/M = DATE;
-* Here I am trying to mimic two columns of data as per your post
  CP/D20.2c  = IF SUM_TYPE EQ 'CP ' AND CUR_PERIOD EQ 4 THEN DOLLARS ELSE 0;
  YTD/D20.2c = IF SUM_TYPE EQ 'YTD' AND CUR_PERIOD LE 4 THEN DOLLARS ELSE 0;
END

TABLE FILE GGSALES
SUM  CP 
OVER YTD
BY PRODUCT PAGE-BREAK
BY CITY
BY STCD
ACROSS REGION ROW-TOTAL AS 'All Regions'
WHERE DATE FROM '19960101' TO '19961231'
ON PRODUCT SUBTOTAL AS 'Total for '
END
-RUN

Good luck

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Member
posted Hide Post
Thanks for you input! I am not using an over. I have 2 separate records in a file I created. One for 'CP' and one for 'YTD'. I am usinga match to put the two records in the same file. I could change it and use the over and see if that works. Great ideas!


WF 7.1.6 Platform Windows; Databases Informix, msSQL2000, msSQL2005, Unisys DMSII
Output HTML, EXCEL, PDF
 
Posts: 11 | Location: Salt Lake City, Utah | Registered: May 15, 2006Report This Post
Expert
posted Hide Post
T, this might be for you:

http://www.scaryideas.com/print/2960/


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Expert
posted Hide Post
Thanks Francis, but I already have a few hundred of those tools and they really do have thousands of uses Wink my favorite is replacing Grannies crochet hook when she's put it down and can't remember where she left it - rofl



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report 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     Totalling across values.

Copyright © 1996-2020 Information Builders