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 have a report with PDF output. The report is set up to do a page break on employee so that the end report has one page per employee. The problem is that some employees have enough data that it creates a 2nd page for that employee. It's not a problem to have multiple pages for the employee, but is there a way to control where the report breaks to the 2nd page based on the amount of data?
Thanks for your help! Bethany
Server Environment:Win2K3 Server Apache Tomcat standalone application server WF 7.1.3 DevStudio 7.1.4
Server Environment: Win2K3 Server WebFOCUS 7.13 Apache Tomcat standalone application server
if i understand you correctly, you don't want to page-break if the last employee has only a few remaining lines of data, is that right? you can set up some switches
-* how many lines per page do you want
-SET &mylpp = 66 ;
-* how many lines tolerable for nobreak
-SET &mymin = 10 ;
-* a simple flag that increments on employee change
BODYCOUNT/I8=IF EMPLOYEE EQ LAST EMPLOYEE THEN LAST BODYCOUNT ELSE 1+ LAST BODYCOUNT;
-* whats the max lines per employee
LINENUM/I8=IF EMPLOYEE EQ LAST EMPLOYEE THEN LAST LINENUM + 1 ELSE 1;
-* how many remainder lines
REMAIN/I2=IMOD( LINENUM, &mylpp , 'I2');
-* now a fake page-breaker ;
-* when you encounter a new guy and
-* the end of the last guy is less than your page break criteria
-* then dont page break.
DEALorNODEAL/I8=IF (EMPLOYEE NE LAST EMPLOYEE) AND ( LAST REMAIN LE &mymin) THEN LAST BODYCOUNT ELSE BODYCOUNT;
ON DEALorNODEAL PAGE-BREAK
ON EMPLOYEE SUBHEAD ...
(mske sure you have nice subheads to id the employee if you switch mid page) ...This message has been edited. Last edited by: susannah,
In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003
It used to work, haven't in a while though. I know in the 5.3.6 world I had a report I'd used it with due to footers. Suppose this is something that was 'fixed' recently.
Leah
Posts: 1317 | Location: Council Bluffs, IA | Registered: May 24, 2004
Hi, Bethany. I have what is an approach, more than a solution. I will shorthand it, on the assumption that you've been doing this a while, and can fill in the details.
This approach requires two passes (at least) at the data. First pass, in addition to printing your data, you count the number of lines per employee (emp_counter). Put that in a hold file. Second pass (the report, hopefully), you create some kind of field to break on. For example, you might use IMOD to get the remainder of a divison of emp_counter by 50. That remainder (emp_remainder) would be zero on every fiftieth record. Maybe create another variable - say pg_count - that starts at 1 and is incremented when emp_remainder = 0. So it's 1 for the first 50 records, 2 for the next 50, etc. Then sort by employee within pg_count and page-break on employee. Or by pg_count within employee and break on pg_count. Either will work, as long as you handle the details properly.
You can build a more sophisticated algorithm, if you want. Might take a third pass (not sure). You could specify a page break within employee at 50 lines only if the total lines for the employee exceeds 60, for example. The important point is counting lines by employee and using that to control the page break.
dwf
Posts: 135 | Location: Portland, OR | Registered: March 23, 2005
Thanks for the suggestions/solutions. I was able to make it work by adding an additional sort field and then use the NO SPLIT on the that field. I'll save the other solutions for another time when NOSPLIT won't do the trick...and I'm sure that day will eventually come.
Thanks again!
Server Environment: Win2K3 Server WebFOCUS 7.13 Apache Tomcat standalone application server