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] Summarization/totals

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Summarization/totals
 Login/Join
 
Gold member
posted
Dear All, thank you in advance for your help end sorry if question is too simple/naive.

I have file SALES like

Region Place Amount
A London 2
B London 2
A Paris 2
B Paris 2
A Berlin 2

And I need to get Report like

Region Place Amount
A Berlin 2
London 2
Paris 2
B London 2
Paris 2
Total 10
Berlin 2
London 4
Paris 4

Line Total is not essencial, but idea is that first I group/sum data by Region and after that at the end of report I need to show data by Place.

At the moment I can form such report in few runs.
TABLE FILE SALES
SUM
COMPUTE REGION/A10='';
AMOUNT
BY PLACE
ON TABLE HOLD AS H1
END

TABLE FILE SALES
SUM
AMOUNT
BY REGION
BY PLACE
ON TABLE HOLD AS H2
END
-RUN


TABLE FILE H2
PRINT *
MORE
FILE H1
END

Can I do such report in one run, using TOTAL or SUBFOOTER, multiverb functionality or even in some other more simple way?

Thanks for advise

Piter
---
WF7.7.03

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


Wf7704/WF8,Win64/32
 
Posts: 68 | Registered: February 20, 2004Report This Post
Master
posted Hide Post
Hi Piter,

You've got a nice solution.

Why do you want another one? Because of performance? ( not having to query twice ? )

You could
TABLE FILE SALES
 SUM AMOUNT
 BY REGION
 BY PLACE
ON TABLE HOLD AS H_REGION_PLACE
END

TABLE FILE H_REGION_PLACE
 SUM COMPUTE REGION/A10 = '';
     AMOUNT
 BY  PLACE
ON TABLE HOLD AS H_PLACE
END

TABLE FILE H_REGION_PLACE
 PRINT *
MORE
FILE H_PLACE
END


Slight difference with your version is that I use the data from the first HOLD to fill the second one. ( since the data is there anyway ).

This results in only one actual query. But when the HOLD file is big you might not gain performance.

G'luck hope this helps?


_____________________
WF: 8.0.0.9 > going 8.2.0.5
 
Posts: 668 | Location: Veghel, The Netherlands | Registered: February 16, 2010Report This Post
Gold member
posted Hide Post
Thank you, Dave. Nice note! Power of WF - no need to overload db Smiler

But in fact, coming to my initial request - there is no way to have something like

table file somefile
sum
amounts
by country
by product
totals
where total by product makes
end

Smiler?


Wf7704/WF8,Win64/32
 
Posts: 68 | Registered: February 20, 2004Report This Post
Virtuoso
posted Hide Post
In the basic you can only get the data once in a report. But of course you are not the first with this problem

And as said before there are several solutions. You did one.
Mcguyver is an other, FML is also one you might like.
With multiverb you can create the totals in an other way, hide it and use it in the footing.
You can also build two separate reports and combine them in one compound report.

So....many ways to skin a cat...




Frank

prod: WF 7.6.10 platform Windows,
databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7
test: WF 7.6.10 on the same platform and databases,IE7

 
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006Report This Post
Gold member
posted Hide Post
Thank you Frank for point to Mcguyver techniques. Interesting one!

FML - yes, but it cost additionally and in fact my situation solved by few HOLD successfuly


Wf7704/WF8,Win64/32
 
Posts: 68 | Registered: February 20, 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     [SOLVED] Summarization/totals

Copyright © 1996-2020 Information Builders