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] Row total for one column

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Row total for one column
 Login/Join
 
Master
posted
Hi,
I'm trying to get the Row total for only one column not for the all columns in verb request.

The sample code is below,
TABLE FILE CAR
SUM DEALER_COST
RETAIL_COST
BY CAR
ACROSS COUNTRY
ON TABLE ROW-TOTAL
END
-EXIT

If you see the Total, you will see both dealer and retail cost. I want to see the row total only for Dealer_Cost.

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


WFConsultant

WF 8105M on Win7/Tomcat
 
Posts: 780 | Location: Florida | Registered: January 09, 2005Report This Post
Virtuoso
posted Hide Post
Use RECAP after ACROSS to add a summary column on the right. Try this (untested):
TABLE FILE CAR
SUM DEALER_COST NOPRINT
SUM DEALER_COST RETAIL_COST
BY CAR
ACROSS COUNTRY
RECAP DC_TOTAL=C1;
END
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report This Post
Platinum Member
posted Hide Post
Try this.

TABLE FILE CAR
SUM DEALER_COST AS 'Tot Dealer'
BY CAR
SUM DEALER_COST
RETAIL_COST
BY CAR
ACROSS COUNTRY
END


WF 8 version 8.2.04. Windows.
In focus since 1990.
 
Posts: 189 | Location: pgh pa | Registered: October 06, 2004Report This Post
Virtuoso
posted Hide Post
Hopefully there is a better way...but I got around this recently by creating a compute field with what I wanted.
COMPUTE TOT/D9MB = DEPT1+DEPT2 ; AS TOTAL
Then just printing it at the end.


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
 
Posts: 1903 | Location: San Antonio | Registered: February 28, 2005Report This Post
Platinum Member
posted Hide Post
add the BY CAR after the first verb in j.g. solution and it works fine.

TABLE FILE CAR
SUM DEALER_COST NOPRINT
BY CAR
SUM DEALER_COST RETAIL_COST
BY CAR
ACROSS COUNTRY
RECAP DC_TOTAL=C1;
END


WF 8 version 8.2.04. Windows.
In focus since 1990.
 
Posts: 189 | Location: pgh pa | Registered: October 06, 2004Report This Post
Master
posted Hide Post
Hi JG and Spence,
Yes, this code works but I want the label to say as Total, Dealer, Cost.


Example:
TABLE FILE CAR
SUM DEALER_COST NOPRINT
BY CAR
SUM DEALER_COST RETAIL_COST
BY CAR
ACROSS COUNTRY
RECAP DC_TOTAL=C1; AS 'Total, Dealer, Cost'
END

The problem is, it is displaying Total Dealer Cost in one line. The comma is not working as how it works in Title(start in next line).


WFConsultant

WF 8105M on Win7/Tomcat
 
Posts: 780 | Location: Florida | Registered: January 09, 2005Report This Post
Virtuoso
posted Hide Post
I just ran the code in our windows 5.3.4 and the title for the DC_TOTAL came out as three lines. Moment here, it is not removing the comma is what you're saying? I ran without the commas to HTML out and it wrapped the header but then that may be due to html.


Leah
 
Posts: 1317 | Location: Council Bluffs, IA | Registered: May 24, 2004Report This Post
Platinum Member
posted Hide Post
quote:
DC_TOTAL

try this.

TABLE FILE CAR
SUM DEALER_COST NOPRINT
BY CAR
SUM DEALER_COST RETAIL_COST
BY CAR
ACROSS COUNTRY
RECAP 'Total Dealer Cost'=C1;
END


WF 8 version 8.2.04. Windows.
In focus since 1990.
 
Posts: 189 | Location: pgh pa | Registered: October 06, 2004Report This Post
Master
posted Hide Post
Hi Spence,
This code works. Thanks


WFConsultant

WF 8105M on Win7/Tomcat
 
Posts: 780 | Location: Florida | Registered: January 09, 2005Report This Post
Silver Member
posted Hide Post
Hi,

I used this solution because I didn't need a row total for all my across columns.

Worked great so thank you!

Now the problem...

At first, all the RECAPs were printing 2 decimals even if the original columns were not formatted that way. Then, I had to change the format of some of the columns so the $ would print. Now, my RECAP totals are size 10 font instead of size 8 like the rest of my columns (only the data, the titles are fine).

I've tried referring to them by Cn and by the field name. No dice. Any ideas?

Thanks,

Krysti


WF 767
 
Posts: 34 | Location: Chicago, IL | Registered: September 02, 2004Report This Post
Silver Member
posted Hide Post
Nevermind. I got it to work.

I added a format to the RECAPs and it picked up the size 8 font. No idea why, but it did!


WF 767
 
Posts: 34 | Location: Chicago, IL | Registered: September 02, 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] Row total for one column

Copyright © 1996-2020 Information Builders