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.
After searching the forums and reading webfocus tutorials i still haven't been able to recompute my across total column correctly. I didn't know how to reproduce the problem with the focus sample databases provided so i just insert hereby the whole code for the report i want to produce.
aLL I want is to get M% recomputed correctly on row level.
SET FOCTRANSFORM = ON
SET EMPTYREPORT = ON
SET CDN = ON
TABLE FILE BV1
SUM
'BV1.TRANSACTIONS.amount/P17.2C'
AS 'WITHDRAWALS'
'CNT.BV1.TRANSACTIONS.ACCOUNT/I7C' AS 'No_Of_Loans'
COMPUTE M1/D6.2% = BV1.INTEREST.INTEREST / CNT.BV1.TRANSACTIONS.ACCOUNT;
AS 'M%'
BY 'BV1.BRANCH.CODE'
BY 'BV1.BRANCH.BRANCH'
ACROSS 'BV1.PRODUCTS.S_PRODUCT_GROUP_NM' AS '' ACROSS-TOTAL
ON TABLE SUBHEAD
"My report header"
HEADING
"My page heading"
WHERE BV1.TRANSACTIONS.MONTHLY_DATA AND ( BV1.PRODUCTS.ΟΝΟΜΑ EQ 'ΕΚ' OR 'ΕΠ' OR 'ΚΚΕ' OR 'Ε1-2' );
ON TABLE SET PAGE-NUM OFF
ON TABLE SUMMARIZE BV1.TRANSACTIONS.amount BV1.TRANSACTIONS.ACCOUNT M1 AS 'TOTAL'
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
INCLUDE = 'tt_dw',
$
UNITS=IN,
PAGESIZE='A4',
LEFTMARGIN=0.250000,
RIGHTMARGIN=0.250000,
TOPMARGIN=0.250000,
BOTTOMMARGIN=0.250000,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
FONT='ARIAL',
SIZE=9,
RIGHTGAP=0.125000,
$
TYPE=DATA,
COLUMN=N2,
BORDER-RIGHT=LIGHT,
BORDER-RIGHT-STYLE=DOUBLE,
BORDER-RIGHT-COLOR=RGB(51 51 153),
$
TYPE=DATA,
ACROSSCOLUMN=N3,
BORDER-RIGHT=LIGHT,
BORDER-RIGHT-STYLE=DOUBLE,
BORDER-RIGHT-COLOR=RGB(51 51 153),
$
TYPE=TITLE,
STYLE=BOLD,
$
TYPE=TITLE,
COLUMN=N2,
BORDER-RIGHT=LIGHT,
BORDER-BOTTOM-STYLE=RIDGE,
BORDER-RIGHT-STYLE=DOUBLE,
$
TYPE=TITLE,
ACROSSCOLUMN=N3,
BORDER-BOTTOM=LIGHT,
BORDER-LEFT=LIGHT,
BORDER-RIGHT-STYLE=DOUBLE,
$
TYPE=TABHEADING,
SIZE=12,
STYLE=BOLD,
$
TYPE=TABHEADING,
LINE=1,
OBJECT=TEXT,
ITEM=1,
SIZE=10,
$
TYPE=TABFOOTING,
SIZE=12,
STYLE=BOLD,
$
TYPE=HEADING,
SIZE=12,
STYLE=BOLD,
$
TYPE=HEADING,
LINE=1,
JUSTIFY=LEFT,
$
TYPE=FOOTING,
SIZE=12,
STYLE=BOLD,
$
TYPE=SUBHEAD,
SIZE=10,
STYLE=BOLD,
$
TYPE=SUBFOOT,
SIZE=10,
STYLE=BOLD,
$
TYPE=SUBTOTAL,
BACKCOLOR=RGB(210 210 210),
$
TYPE=ACROSSVALUE,
SIZE=9,
$
TYPE=ACROSSTITLE,
STYLE=BOLD,
$
TYPE=GRANDTOTAL,
BACKCOLOR='NONE',
STYLE=BOLD,
$
ENDSTYLE
END
By the way ------------ ACROSS RECOMPUTE 'BV1.PRODUCTS.S_PRODUCT_GROUP_NM' AS '' ACROSS-TOTAL--------- IS NOT ACCEPTED. wHY?This message has been edited. Last edited by: Vas,
TABLE FILE CAR
SUM
SALES
RETAIL_COST AS 'RETAIL'
DEALER_COST AS 'DEALER'
COMPUTE M1/D6.2% = RETAIL_COST / DEALER_COST;
ACROSS COUNTRY RECOMPUTE
BY SEATS
END
Francis
Give me code, or give me retirement. In FOCUS since 1991
Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
Francis thank you very much for reply! I appreciate it a lot.
I have read the specific tutorial many times and i have tried to apply the techniques. So in my code that would be:
ACROSS 'BV1.PRODUCTS.S_PRODUCT_GROUP_NM' RECOMPUTE AS 'CORRECT ACROSS TOTAL'
However if i try this what i get is the following Error:
FOC32498) FOCEXEC PARSER ERROR. INVALID SYMBOL: RECOMPUTE --------------------------------------------------------vvvvvvvvv ACROSS 'BV1.PRODUCT.S_PRODUCT_GROUP_NM' RECOMPUTE AS 'CORRECT AC (FOC32498) FOCEXEC PARSER ERROR. INVALID SYMBOL: AS ------------------------------------------------------------------vv ACROSS 'BV1.PRODUCT.S_PRODUCT_GROUP_NM' RECOMPUTE AS 'CORRECT AC (FOC32498) FOCEXEC PARSER ERROR. INVALID SYMBOL: 'CORRECT ACROSS TOTAL' ---------------------------------------------------------------------vvvvvvvvvv ACROSS 'BV1.PRODUCT.S_PRODUCT_GROUP_NM' RECOMPUTE AS 'CORRECT AC 0 ERROR AT OR NEAR LINE 8 IN PROCEDURE test FOCEXEC * (FOC003) THE FIELDNAME IS NOT RECOGNIZED: BV1.TRANSACTIONS.TRANSACTIONS.amount/P17.2C BYPASSING TO END OF COMMAND (FOC009) INCOMPLETE REQUEST STATEMENT
TABLE FILE CAR
SUM
'CAR.BODY.SALES/D12' AS 'Sales'
'CAR.BODY.RETAIL_COST' AS 'Retail,Cost'
'CAR.BODY.DEALER_COST' AS 'Dealer,Cost'
COMPUTE M1/D6.2% = CAR.BODY.RETAIL_COST / CAR.BODY.DEALER_COST; AS '%'
BY 'CAR.BODY.SEATS' AS 'Seats'
ACROSS 'CAR.ORIGIN.COUNTRY' AS '' RECOMPUTE AS 'TOTAL COUNTRIES'
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE NOTOTAL
ON TABLE SET STYLE *
UNITS=IN,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
GRID=OFF,
FONT='ARIAL',
SIZE=9,
COLOR='BLACK',
STYLE=NORMAL,
$
TYPE=TITLE,
STYLE=BOLD,
$
TYPE=ACROSSVALUE,
ACROSS=1,
COLOR='BLUE',
JUSTIFY=CENTER,
$
TYPE=ACROSSTITLE,
ACROSS=1,
COLOR='BLUE',
JUSTIFY=CENTER,
$
ENDSTYLE
END
This code was generated by Dev Studio Report Painter, EXCEPT for RECOMPUTE AS 'TOTAL COUNTRIES' which the v7.6.5 GUI removes when you switch from the Source tab to the Report tab and back to the Source tab. It appears that this feature is only documented in the "Creating Reports With WebFOCUS Language" manual, therefore it's not yet compatible with Report Painter, though this does not explain why you get the error, I can't believe they removed this option in v7.6.9.
Francis
Give me code, or give me retirement. In FOCUS since 1991
Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
Your code runs just fine! The v7.6.5.9 GUI also removes the RECOMPUTE AS 'TOTAL COUNTRIES' code bit.
So i really don't get what is wrong with my code.
I would also like to ask you, if there is any other way to recompute the across total column correctly in a way that the GUI is synchronized with the code. ??
If you've tried to code something similar to the working example I posted, and it does not work, perhaps no one here can explain that. How about opening a case with Tech Support?
Francis
Give me code, or give me retirement. In FOCUS since 1991
Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server