Focal Point
[CLOSED] Grand Totals on top ?

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/61310824

March 13, 2009, 10:27 AM
shravan
[CLOSED] Grand Totals on top ?
Hi all,

Is there a way to make "Grand Totals" appear on the top and also at the bottom ?

Thank you,

Shravan

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


7.7.03, Windows 7, SQL Server 2005
March 13, 2009, 11:27 AM
GinnyJakes
TABLE FILE CAR
SUM SALES 
BY COUNTRY
ON TABLE COLUMN-TOTAL
HEADING
"<TOT.SALES"
END



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
March 13, 2009, 11:54 AM
shravan
Thanks, Ginny.

But this way doesn't it appear on all the pages ? So, may be I will add a condition so that it will appear only on the first page.


7.7.03, Windows 7, SQL Server 2005
March 13, 2009, 12:09 PM
RSquared
Just add

/*
ON TABLE SUBHEAD
"
instead of the HEADING


WF 7.6.11
Oracle
WebSphere
Windows NT-5.2 x86 32bit
March 17, 2009, 09:03 AM
Danny-SRL
Shravan,

There is a new SET command in WF7.6. See below:
  
-* File shravan3.fex
SET DUPLICATECOL=OFF
TABLE FILE CAR
SUM SALES
PRINT SALES BY COUNTRY BY CAR BY BODYTYPE
ON TABLE COLUMN-TOTAL
END



Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF

March 17, 2009, 09:13 AM
GinnyJakes
Danny,

This is in 7.6.7, not in 7.6.5 which he has. Trust me. I tried it and it doesn't work.

But it would be a great solution.


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
March 17, 2009, 09:17 AM
Danny-SRL
Oh, well...
Then one can always trust Mc Guyver:
  
JOIN BLANK WITH SALES IN CAR TO BLANK IN FSEQ AS B_
DEFINE FILE CAR
BLANK/A1 WITH SALES=' ';
XCOUNTRY/A10=IF COUNTER EQ 1 THEN 'Grand' ELSE COUNTRY;
XCAR/A16=IF COUNTER EQ 1 THEN ' ' ELSE CAR;
COUNTRYSORT/A1=IF COUNTER EQ 1 THEN 'T' ELSE ' ';
END
TABLE FILE CAR
IF COUNTER LE 2
SUM SALES
BY HIGHEST COUNTRYSORT NOPRINT
SUBTOTAL AS 'Grand' WHEN COUNTRYSORT NE 'T'
BY XCOUNTRY  AS COUNTRY
BY XCAR AS CAR
ON TABLE NOTOTAL
ON TABLE SET HTMLCSS ON
END



Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF

March 25, 2009, 06:08 AM
VidyaCA
Hi Shravan,

If this is the solution you are looking for then please have a look at the below code:



SALES SEATS WEIGHT
TOTAL 208420 70 45,791
ENGLAND 12000 13 13,876
FRANCE 0 5 2,860
ITALY 30200 10 10,915
JAPAN 78030 8 4,269
W GERMANY 88190 34 13,871
TOTAL 208420 70 45,791

--------------------


TABLE FILE CAR
SUM
COMPUTE ORDER/I1 = 2;
SALES
SEATS
WEIGHT
BY COUNTRY
ON TABLE HOLD AS CONTFL FORMAT ALPHA
END

TABLE FILE CONTFL
SUM
COMPUTE ORDER/I1 = 1;
COMPUTE COUNTRY/A10 = 'TOTAL';
SALES
SEATS
WEIGHT
ON TABLE HOLD AS TOTFL1 FORMAT ALPHA
END

TABLE FILE TOTFL1
SUM
COMPUTE ORDER/I1 = 3;
COMPUTE COUNTRY/A10 = 'TOTAL';
SALES
SEATS
WEIGHT
ON TABLE HOLD AS TOTFL2 FORMAT ALPHA
END

TABLE FILE TOTFL1
PRINT
SALES
SEATS
WEIGHT
BY ORDER NOPRINT
BY COUNTRY
MORE
FILE CONTFL
MORE
FILE TOTFL2
END


WF 764
Windows
Excel, HTML, PDF, XML
March 25, 2009, 06:41 AM
Danny-SRL
Vidya,

Your solution entails reading the file 4 times and the use of MORE. I suggest that the use of the McGuyver technique is more economical.


Daniel
In Focus since 1982
wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF