April 04, 2007, 11:40 AM
mgrackinKamesh,
Add WRAP=#.## settings to your request.
1) Make sure the WRAP is set for both the ACROSSVALUE and the ACROSSCOLUMN.
2) Make sure the WRAP value is wide enough for both the across values and the across column values.
3) Make sure the WRAP value is EXACTLY THE SAME in both statements.
For Example:
TABLE FILE CAR
SUM DEALER_COST/D12.1 AS ''
BY COUNTRY AS ''
ACROSS CAR AS ''
WHERE RECORDLIMIT EQ 10
ON TABLE PCHOLD FORMAT PDF
ON TABLE SET STYLE *
TYPE=REPORT,GRID=OFF,SQUEEZE=ON,SIZE=7,
WRAP=0.60,$TYPE=ACROSSVALUE,COLOR=GREEN,JUSTIFY=RIGHT,
WRAP=0.60,$TYPE=REPORT,ACROSSCOLUMN=DEALER_COST,JUSTIFY=RIGHT,COLOR=RED,$
ENDSTYLE
END
April 04, 2007, 11:44 AM
KameshThanks Mickey, it works like a charm.
I didn't understand how the WRAP makes the difference.
April 04, 2007, 11:46 AM
Francis MarianiOddly, if you change the format of DEALER_COST to, say, D12.3, it aligns correctly.
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
April 04, 2007, 02:53 PM
mgrackinKamesh,
Here is a link to the PART 1 article I wrote which talks about SQUEEZE and WIDTH.
http://www.informationbuilders.com/support/developers/htmlpdf.htmlIn regards to your experience with your request, I suggest opening a case with IBI Tech Support. This looks like it may be an issue/bug.
Francis,
Here's my guess why it didn't work as expected:
The engine that creates the PDF probably applied the SQUEEZE to the ACROSSVALUES seperately from the ACROSSCOLUMN values. Therefore it came up with a different column width for the ACROSSVALUES for CAR than it did for the ACROSSCOLUMN values for DEALER_COST. Applying the WRAP setting forces the same column width for both. Judging from the way the results appear, this looks like it may be what is happening. Changing the format for DEALER_COST makes it longer so the calculated column width for DEALER_COST is wider. Ironically if you make the format D12.6 everything still works because the column width for the ACROSSVALUES adjusts to match the column width for DEALER_COST values.
Very interesting.