I went into the following situation ( example here is with the CAR file ):
DEFINE FILE CAR
TEMP/D8.1S- = -WIDTH;
END
-RUN
TABLE FILE CAR
PRINT
WIDTH
TEMP
ON TABLE PCHOLD AS SOMEPDF FORMAT PDF
ON TABLE SET STYLE *
UNITS=IN,
PAGESIZE='A4',
LEFTMARGIN=0.250000,
RIGHTMARGIN=0.250000,
TOPMARGIN=0.250000,
BOTTOMMARGIN=0.250000,
SQUEEZE=ON,
ORIENTATION=LANDSCAPE,
$
TYPE=REPORT,
FONT='COURIER NEW',
SIZE=10,
COLOR='BLACK',
BACKCOLOR='NONE',
STYLE=BOLD,
LEFTGAP=0.00001,
RIGHTGAP=0.00001,
$
TYPE=DATA,
SIZE=6,
BACKCOLOR=( RGB(234 234 255) 'WHITE' ),
$
TYPE=REPORT,
COLUMN = WIDTH,
SQUEEZE = 4,
COLOR = RED,
$
COLUMN = TEMP,
SQUEEZE = 2,
COLOR = RED,
-* JUSTIFY = CENTER,
$
ENDSTYLE
END
-RUN
-EXIT
Problem is with the TEMP field - when I use squeeze on it ( without justify ) the field disappears. I want it to be justified right but when I use JUSTIFY = RIGHT , the field disappears again. The only way TEMP field is printed is by not using squeeze or using JUSTIFY = CENTER. Why is this happening and how can I fix it ? ( I want the TEMP field justified right but without converting it to alphanumeric - that will do the job but I do not want to convert it.) Thanks in advance .This message has been edited. Last edited by: Kerry,
WF 7.6.5 / OS: XP / FOCUS
October 02, 2008, 09:03 AM
Prarie
Try changing Squeeze to WRAP. You might need GRID=ON also.
In Focus since 1993. WebFOCUS 7.7.03 Win 2003
October 02, 2008, 09:28 AM
Martin_fmi
Tried both of them but it is not working again. I can't find what is the trick with this one.
WF 7.6.5 / OS: XP / FOCUS
October 02, 2008, 10:14 AM
Francis Mariani
I'd say it's a bug - it only occurs if your column definition contains a negative sign, as in D8.1S-. If you use D8.1S the style-sheet declaration works.
If you explain what you are attempting to achieve, perhaps we can help. Why are you using SQUEEZE on a numeric column? Wouldn't LEFTGAP on the column do the same thing?
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
October 02, 2008, 10:42 AM
FrankDutch
The SQUEEZE function is for reducing the needed space in a alpha string field to the available space.
Suppose you have a field with size A20 and that holds the names of you customers, but you have not enough space in the report you can squeeze the space to less than the needed A20. Now it displays only the first say 10 characters. What you will see is something like
The "!" indicates that there are more characters but the field is abbreviated in the report.
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
October 03, 2008, 03:13 AM
Martin_fmi
Francis - tried with leftgap / rightgap but it is not showing again. Anyway the problem is solved converting it to an alphanumeric field. Thanks. Frank - I've always used squeeze not only with alphanumeric but even with numeric and all sorts of fields ( yymd e.g.) and it works. But this is the first I encounter this problem. If it is a bug - I would have it in mind. Thanks a lot guys .
WF 7.6.5 / OS: XP / FOCUS
October 06, 2008, 02:29 PM
Martin_fmi
Here is a solution to the problem ( with the example above ):
DEFINE FILE CAR
TEMP_T/D8.1S = -WIDTH;
MYFORMAT/A8 = 'D8.1S-';
END
-RUN
TABLE FILE CAR
PRINT
WIDTH
TEMP_T/MYFORMAT
ON TABLE PCHOLD AS SOMEPDF FORMAT PDF
ON TABLE SET STYLE *
UNITS=IN,
PAGESIZE='A4',
LEFTMARGIN=0.250000,
RIGHTMARGIN=0.250000,
TOPMARGIN=0.250000,
BOTTOMMARGIN=0.250000,
SQUEEZE=ON,
ORIENTATION=LANDSCAPE,
$
TYPE=REPORT,
FONT='COURIER NEW',
SIZE=10,
COLOR='BLACK',
BACKCOLOR='NONE',
STYLE=BOLD,
LEFTGAP=0.00001,
RIGHTGAP=0.00001,
$
TYPE=DATA,
SIZE=6,
BACKCOLOR=( RGB(234 234 255) 'WHITE' ),
$
TYPE=REPORT,
COLUMN = N1,
SQUEEZE = 4,
$
COLUMN = N2,
SQUEEZE = 4,
JUSTIFY=RIGHT,
$
ENDSTYLE
END
-RUN
-EXIT