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.
I am doing an across in my report and I am drilling down on Across coumn. How do I supress drill down on Across total? TABLE FILE CAR SUM DEALER_COST BY COUNTRY ACROSS CAR AS ' ' ACROSS-TOTAL WHERE RECORDLIMIT EQ '10000' ON TABLE SET STYLE * TYPE=ACROSSVALUE, ACROSS=1, STYLE=BOLD, TARGET='_blank', JUSTIFY=CENTER, FOCEXEC=CAR, $ ENDSTYLE END
I've tried a lot of different things, but there's no way to address the ACROSS-TOTAL column. With the 5.3.2 Dev Studio Report Painter, you can only change the title of the column from "TOTAL" to something else. It would appear that the ACROSS-TOTAL column was overlooked when WebFOCUS Style Sheet was created.
Here's an inelegant method to get around this problem, using a two-verb request:
TABLE FILE CAR
SUM DEALER_COST AS 'TOTAL'
BY COUNTRY
SUM DEALER_COST AS ' '
BY COUNTRY
ACROSS CAR AS ' '
ON TABLE SET STYLE *
TYPE=ACROSSVALUE,
ACROSS=1,
STYLE=BOLD,
TARGET='_BLANK',
JUSTIFY=CENTER,
FOCEXEC=CAR,
$
ENDSTYLE
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
Frank, it looks like "there's no way to address the ACROSS-TOTAL column", hence no way to "SUPPRESS the drill-down on the total" so I tried to find another way to provide an across total AND disable drill-down, which I think my example does.
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
TABLE FILE CAR
SUM DEALER_COST
BY COUNTRY
ACROSS CAR AS ' ' ACROSS-TOTAL
ON TABLE SET STYLE *
TYPE=ACROSSVALUE,
ACROSS=1,
STYLE=BOLD,
TARGET='_BLANK',
JUSTIFY=CENTER,
FOCEXEC=CAR,
$
TYPE=ACROSSVALUE, COLUMN=ROWTOTAL, COLOR=BLACK, FOCEXEC=NONE, $
ENDSTYLE
END
We would love to know what version you've tested this on.
Cheers,
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
I've had to do this a number of times and I've always gone the long route; seems to work for me. More inelegant than Francis, but... Added code to get column counts...
SET ASNAMES = ON DEFINE FILE CAR CAR_X/A16 = 'TOTAL'; END TABLE FILE CAR SUM DEALER_COST BY COUNTRY BY CAR_X AS 'CAR' ON TABLE HOLD AS H1 END -RUN TABLE FILE CAR SUM DEALER_COST BY COUNTRY BY CAR ON TABLE HOLD AS H2 END -RUN -**************************** -* Find the ACROSS Column Count DEFINE FILE H2 CNT/I5 WITH CAR = 1; END TABLE FILE H2 SUM CNT ON TABLE SAVE AS X1 END -RUN -READ X1 &ACROSS.I5. -****************************
TABLE FILE H2 SUM DEALER_COST BY COUNTRY BY CAR ON TABLE HOLD AS H3 MORE FILE H1 END -RUN DEFINE FILE H3 SORT_EM/I2 = DECODE CAR ('TOTAL' 99 ELSE 1); END TABLE FILE H3 SUM DEALER_COST BY COUNTRY AS '' ACROSS SORT_EM NOPRINT ACROSS CAR AS ' ' ON TABLE SET STYLE *
-SET &CNTR = 1; -REPEAT DRILL &ACROSS TIMES -SET &CNTR = &CNTR + 1; TYPE=ACROSSVALUE, ACROSS=2, STYLE=BOLD, TARGET='_BLANK', JUSTIFY=CENTER, FOCEXEC=CAR, COLUMN=N&CNTR, $ -DRILL ENDSTYLE END -EXITThis message has been edited. Last edited by: Tom Flynn,
SET JSURL=/approot/ibisamp/suppress_total.js
TABLE FILE CAR
SUM
DEALER_COST
BY COUNTRY
ACROSS CAR AS ' '
ACROSS-TOTAL
ON TABLE NOTOTAL
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
TYPE=ACROSSVALUE,
STYLE=BOLD,
TARGET='_blank',
JUSTIFY=CENTER,
FOCEXEC=CAR,
$
ENDSTYLE
END
C:\ibi\apps\ibisamp\suppress_total.js
function changeAllA() {
var anchorList = document.getElementsByTagName("a");
for (var i = 0; i < anchorList.length; i++) {
// alert(anchorList[i].innerHTML + " " + anchorList[i].target);
if (anchorList[i].innerHTML == "TOTAL") {
anchorList[i].parentNode.innerHTML = "TOTAL";
}
}
}
if (window.addEventListener) {
window.addEventListener('load', 'changeAllA', false);
} else if (window.attachEvent) {
window.attachEvent('onload', changeAllA);
} else {
alert("not supported");
}
Should do the trick.
"There is no limit to what you can achieve ... if you don’t care who gets the credit." Roger Abbott
If you have CSS on, then the bolds etc. that are applied to the column titles are applied to the TD tag, not the text in the anchor. All you need to know here is the title for the total column ... in this case "TOTAL". Bolds - or any styling for that matter, and column counts are not required.
"There is no limit to what you can achieve ... if you don’t care who gets the credit." Roger Abbott
TABLE FILE CAR SUM DEALER_COST BY COUNTRY ACROSS CAR AS ' ' ACROSS-TOTAL WHERE RECORDLIMIT EQ '100' ON TABLE SET STYLE * -REPEAT LINKLOOP FOR &CNT FROM 2 TO 11 ; TYPE=ACROSSVALUE, COLUMN=N&CNT, STYLE=BOLD, TARGET='_blank', JUSTIFY=CENTER, FOCEXEC=CAR, $ -LINKLOOP ENDSTYLE END
--- I used your example and use REPEAT logic to add drill down link to all but column N12 which is ACROSSTOTAL.
-Yogesh Patel ------------------------------------------------------------------------ PROD: WF 764 on Linux Apache tomcat v5.5 DEV: WF 768 on Linux
Posts: 42 | Location: Edison, New Jersey | Registered: January 30, 2007
If this works....I will try tomorrow, I love it and you can change the highest value by first counting the expected numbers, and put that number in an amper value.
Frank
prod: WF 7.6.10 platform Windows, databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7 test: WF 7.6.10 on the same platform and databases,IE7
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006
It works and you are right '11' in my example was the ACROSSTOTAL column number for the example we were using, that number can be made dynamic as you said by puting an amper variable.
quote:
Originally posted by ypatel: I love solving problems , how about this !!
TABLE FILE CAR SUM DEALER_COST BY COUNTRY ACROSS CAR AS ' ' ACROSS-TOTAL WHERE RECORDLIMIT EQ '100' ON TABLE SET STYLE * -REPEAT LINKLOOP FOR &CNT FROM 2 TO 11 ; TYPE=ACROSSVALUE, COLUMN=N&CNT, STYLE=BOLD, TARGET='_blank', JUSTIFY=CENTER, FOCEXEC=CAR, $ -LINKLOOP ENDSTYLE END
--- I used your example and use REPEAT logic to add drill down link to all but column N12 which is ACROSSTOTAL.
-Yogesh Patel ------------------------------------------------------------------------ PROD: WF 764 on Linux Apache tomcat v5.5 DEV: WF 768 on Linux
Posts: 42 | Location: Edison, New Jersey | Registered: January 30, 2007
-**************************** -* Find the ACROSS Column Count DEFINE FILE H2 CNT/I5 WITH CAR = 1; END TABLE FILE H2 SUM CNT ON TABLE SAVE AS X1 END -RUN -READ X1 &ACROSS.I5. -**************************** then: