Focal Point
[SOLVED] Column-Total

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

September 23, 2008, 08:54 AM
Suji
[SOLVED] Column-Total
Hi,
I have a field with positive and negative values.I have to just do column-total of its absolute values. Is it feasible with Webfocus?
For example,there is a column called Price as shown below.

Price
7
-9
3
-1
Column-total has to be 20(It should not be 0)

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


WebFOCUS 7.7.02(Production)
WebFOCUS 7.7.02(Test region)
Oracle backend (10g)and Windows Frontend.
HTML,PDF,EXL2K,FLEX,AHTML
September 23, 2008, 09:07 AM
GamP
I would create a defined field that holds the absolute value of the database field, and sum that field in stead of the db field.


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
September 23, 2008, 09:30 AM
Suji
Hi,
I want to show the summed up value of absolute values at the bottom of the db field. Is it possible to show it ?


WebFOCUS 7.7.02(Production)
WebFOCUS 7.7.02(Test region)
Oracle backend (10g)and Windows Frontend.
HTML,PDF,EXL2K,FLEX,AHTML
September 23, 2008, 09:46 AM
GinnyJakes
As GamP said, do a DEFINE using the ABS function to get the absolute value for your data base field. Then sum that field and get a column-total of it.

Are you wanting to sum the db field as well?

BTW, there is no WebFOCUS 7.4.1 release. You might want to check your signature. I suspect it is 7.1.4 but could be 7.6.1. Confused


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
September 24, 2008, 09:42 AM
PBrightwell
If you are wanting to show the negatives in your report but only the ABS of the Total use RECAP with SUBFOOT. It would be something like:
TABLE FILE MYFILE
SUM AMT
COMPUTE ABS_AMT/D12=ABS(AMT); NOPRINT
ON TABLE RECAP GT/D12=ABS(TOT.ABS_AMT);
ON TABLE SUBFOOT
"Absolute Total END


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
October 01, 2008, 06:16 AM
Suji
Hi,
I am not able to get column-total in the subfoot right after the report output in PDF format since I give pagenum at the footing bottom. Is there any way to introduce table border in the subfoot also in PDF format?

For example,this is my sample output how it appears in my PDF format
Country ITEM Price
India A $5
US B $10
Arab C $15



1
$30
===============================================
But I want it to be as follows

Country ITEM Price
India A $5
US B $10
Arab C $15
$30


1


WebFOCUS 7.7.02(Production)
WebFOCUS 7.7.02(Test region)
Oracle backend (10g)and Windows Frontend.
HTML,PDF,EXL2K,FLEX,AHTML
October 01, 2008, 07:00 AM
<JG>
Suji
A FOOTING can have multiple lines

"Absolute Total <GT"
" "
"<PAGENUM"  


(sorry about the edit. I did the same as Pat and forgot the code tags)