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.
Hi, I'm wanting a field that increments everytime a subhead is printed. I tried this but didn't quite get what I wanted...
DEFINE FILE CAR
KOUNT3/I1=3;
KOUNT/I4 WITH COUNTRY=IF KOUNT GT KOUNT3 THEN KOUNT+1 ELSE 4;
END
TABLE FILE CAR
SUM
DEALER_COST
RETAIL_COST
BY COUNTRY
BY CAR
BY BODYTYPE
ON COUNTRY SUBHEAD
" INCREMENTER HEADING VALUE IS <KOUNT "
ON COUNTRY SUBTOTAL AS '*TOTAL COUNTRY'
ON CAR SUBTOTAL AS '*TOTAL CAR'
ON BODYTYPE SUBTOTAL MULTILINES AS '*TOTAL BODYTYPE'
HEADING
""
FOOTING
""
ON TABLE SET PAGE-NUM OFF
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
UNITS=IN,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
GRID=OFF,
FONT='ARIAL',
SIZE=9,
$
TYPE=SUBHEAD,
SIZE=10,
STYLE=BOLD,
$
ENDSTYLE
END
I wanted the increments to go in numerical order. The defines doesn't quite work because it gets processed before the sort and the where clauses. So, it increments in the original file order and it increments even if the country is eliminated in a where clause.
TABLE FILE CAR
SUM
DEALER_COST
RETAIL_COST
COMPUTE COUNTIT/I4 = IF COUNTRY EQ LAST COUNTRY THEN COUNTIT ELSE COUNTIT + 1; NOPRINT
BY COUNTRY
BY CAR
BY BODYTYPE
ON COUNTRY SUBHEAD
" INCREMENTER HEADING VALUE IS <COUNTIT "
ON COUNTRY SUBTOTAL AS '*TOTAL COUNTRY'
ON CAR SUBTOTAL AS '*TOTAL CAR'
ON BODYTYPE SUBTOTAL MULTILINES AS '*TOTAL BODYTYPE'
HEADING
""
FOOTING
""
ON TABLE SET PAGE-NUM OFF
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
UNITS=IN,
SQUEEZE=ON,
ORIENTATION=PORTRAIT,
$
TYPE=REPORT,
GRID=OFF,
FONT='ARIAL',
SIZE=9,
$
TYPE=SUBHEAD,
SIZE=10,
STYLE=BOLD,
$
ENDSTYLE
END
Tony is too fast for me, code above shows what he is talking about.
Leah
Posts: 1317 | Location: Council Bluffs, IA | Registered: May 24, 2004