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.



Read-Only Read-Only Topic
Go
Search
Notify
Tools
Percentage in Total
 Login/Join
 
Member
posted
New to WebFOCUS and using Version 8001m. I have a column with dollars and a row total for dollars and a RPCT column to calculate the percantage on each row. I cannot get the percantage to calculate correctly on the column TOTAL row. I've tried recalclate, recap, etc. What am I missing? How can I get the percantage to calculate? Currently in appears to summing the row percantages.

Thanks


WebFOCUS 8009, All Outputs
 
Posts: 26 | Registered: February 28, 2013Report This Post
Virtuoso
posted Hide Post
Welcome to the forum.

Please post the code that has been generated so we can tell what is going on.
 
Posts: 1903 | Location: San Antonio | Registered: February 28, 2005Report This Post
Silver Member
posted Hide Post
Keith,
I tried this in 7.7.03 and it had the result shown:
SET ONLINE-FMT=PDF
TABLE FILE xxxxxxx
SUM FAMOUNT PCT.FAMOUNT
BY YEAR BY SDATE
IF YEAR EQ 2011 OR 2012
ON YEAR RECOMPUTE
END
---------- result ------------
YEARDT    SDATE       FAMOUNT PCT AMOUNT
2011......2011-12-23...264.60...7.92
*TOTAL 2011............264.60...7.92
2012......2012-01-04...264.60...7.92
..........2012-01-05...264.60...7.92
..........2012-01-08...264.60...7.92
..........2012-01-11...264.60...7.92
..........2012-01-18...529.20..15.85
..........2012-02-02...174.60...5.23
..........2012-04-17...174.60...5.23
..........2012-05-03...174.60...5.23
..........2012-05-24...264.60...7.92
..........2012-09-18...523.80..15.69
..........2012-11-01...174.60...5.23
*TOTAL 2012..........3,074.40..92.08
TOTAL................3,339.00.100.00

----------------
The year and grand total appear to be what I expected.
What is you objective ?

This message has been edited. Last edited by: John W Price,



WebFOCUS 8.0.2, FOCUS since 1977 - John@Aviter.com
PDF , Excel, FOCUS, Author of the Keysheets and Dates book.
www.Aviter.com
 
Posts: 40 | Registered: April 19, 2013Report This Post
Virtuoso
posted Hide Post
Keith,

Welcome and be happy you have FOCUS to play with!

Here is a solution:
  
-* File keith01.fex
DEFINE FILE CAR
DUM/A1=' ';
END
TABLE FILE CAR
SUM RCOST NOPRINT
BY DUM NOPRINT
BY COUNTRY
SUM RCOST COMPUTE RPCT_RCOST/D6.2%=C2 / C1 * 100; 
ACROSS SEATS ACROSS-TOTAL
BY DUM RECOMPUTE 
BY COUNTRY
ON TABLE NOTOTAL
END


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

 
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006Report This Post
Member
posted Hide Post
Here's the code, I should have included it the first time.

TABLE FILE VIEW_ARSUMMARY
SUM
VIEW_ARSUMMARY.ARSUMMARY.COUNTINVS/I8C AS 'Count'
VIEW_ARSUMMARY.ARSUMMARY.ARBAL/P10CB!D
RPCT.VIEW_ARSUMMARY.ARSUMMARY.ARBAL/P5.1% AS '% Tot,$ by,Days'
BY &RP_FN01B_Sort4.(,,,).Please select sort field(s).
ACROSS &RP_FN01A_SortAcross1.(ACROSS(,,,)).Please select across field(s). AS 'AR Aging in Days By Invoice Create Date' COLUMNS '0-30' AND '31-60' AND '61-90' AND '91-120' AND '121-150' AND '151-180' AND '>180' AND 'Current' AND '1 Month' AND '2 Months' AND '3 Months' AND '4 Months' AND '5 Months' AND '> 5 Months'
WHERE ( VIEW_ARSUMMARY.ARSUMMARY.ORG EQ '&ORG.ORG:.' ) AND ( VIEW_ARSUMMARY.ARSUMMARY.DEPARTMENT EQ &DEPARTMENT.DEPARTMENT:. ) AND ( VIEW_ARSUMMARY.ARSUMMARY.DIVISION EQ &DIVISION.DIVISION:. ) AND ( VIEW_ARSUMMARY.ARSUMMARY.BILAREA EQ &BILAREA.BILAREA:. ) AND ( VIEW_ARSUMMARY.ARSUMMARY.BILPROV EQ &BILPROV.BILPROV:. ) AND ( VIEW_ARSUMMARY.ARSUMMARY.FYEAR EQ '&FYEAR.FYEAR:.' ) AND ( VIEW_ARSUMMARY.ARSUMMARY.MONTHNAME EQ '&MONTHNAME.MONTHNAME:.' ) AND ( VIEW_ARSUMMARY.LOCATIONS.LOCCAT2 EQ &LOCCAT2.LOCCAT2:. ) AND ( VIEW_ARSUMMARY.ETMROLES.REPCAT1 EQ &REPCAT1.REPCAT1:. ) AND ( VIEW_ARSUMMARY.ARSUMMARY.ASSGNTOROL EQ &ASSGNTOROL.ASSGNTOROL:. ) AND ( VIEW_ARSUMMARY.ARSUMMARY.STATCAT EQ '&STATCAT.STATCAT:.' ) AND ( VIEW_ARSUMMARY.ARSUMMARY.STAGE EQ &STAGE.STAGE:. ) AND ( VIEW_ARSUMMARY.ARSUMMARY.ARAMTLABEL EQ '&ARAMTLABEL.(,,).ARAMTLABEL:.' ) AND ( VIEW_ARSUMMARY.ARSUMMARY.AGEBYBAL EQ '&AGEBYBAL.(FIND VIEW_ARSUMMARY.ARSUMMARY.AGEBYBAL,VIEW_ARSUMMARY.ARSUMMARY.AGEBYBAL IN VIEW_ARSUMMARY).AGEBYBAL:.' );
ON TABLE SET ONFIELD IGNORE
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE ROW-TOTAL AS 'Aging by Days'
ON TABLE COLUMN-TOTAL AS 'TOTAL'
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *


WebFOCUS 8009, All Outputs
 
Posts: 26 | Registered: February 28, 2013Report This Post
Member
posted Hide Post
Below is an example using the CAR file, I cannot get the percentage on the column total to work correctly, it just sums up the percentage. I've tried RECOMPUTE, SUMMARIZE etc.



TABLE FILE CAR
PRINT
CAR.BODY.SALES/I6CM
RPCT.CAR.BODY.SALES/I6% AS 'PCT,CAR.BODY.SALES'
BY LOWEST CAR.COMP.CAR
ACROSS LOWEST CAR.BODY.BODYTYPE
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE ROW-TOTAL AS 'TOTAL'
ON TABLE COLUMN-TOTAL AS 'TOTAL'
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
INCLUDE = endeflt,
$
TYPE=ACROSSVALUE,
ACROSS=1,
BACKCOLOR='WHITE',
$
ENDSTYLE
END


WebFOCUS 8009, All Outputs
 
Posts: 26 | Registered: February 28, 2013Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic


Copyright © 1996-2020 Information Builders