Bug in report with "PAGE TRAILER"
Posted in 1993
Using Informix 4GL 4.10.UE2, SE, SCO 3.2.4 Problem: In a report, in the ON EVERY ROW section, I have a CASE statement. One of the options in the CASE is SKIP TO TOP OF PAGE If I also have a PAGE TRAILER section, then this SKIP TO TOP OF PAGE works only the first time it is invoked; appears to be completely ignored on subsequent times. If there is no PAGE TRAILER section, then the SKIP TO TOP OF PAGE within the CASE works every time. I expect the output from the appended program to be --------------------------- page 1 line 1 page 1 line 2 ^L page 2 line 1 page 2 line 2 ^L page 3 line 1 page 3 line 2 ^L --------------------------- which is what I get (plus a few blank header lines which I have omitted) if the PAGE TRAILER is commented out. With the PAGE TRAILER uncommented, the end of the first page is --------------------------- Page: 1^L page 2 line 1 page 2 line 2 page 3 line 1 page 3 line 2 [lotsa blank lines deleted] --------------------------- Anyone got an explanation for this? Is it a known bug? -SRK database testing main start report rep output to report rep(0, "page 1 line 1") output to report rep(0, "page 1 line 2") output to report rep(1, "") -- New page; works output to report rep(0, "page 2 line 1") output to report rep(0, "page 2 line 2") output to report rep(1, "") -- New page; NOT WORK output to report rep(0, "page 3 line 1") output to report rep(0, "page 3 line 2") finish report rep end main REPORT Rep(Ctrl, Lne) DEFINE Ctrl SMALLINT, -- What to do Lne CHAR(135) OUTPUT PAGE LENGTH 60 REPORT TO "test.lpr" TOP OF PAGE "^L" FORMAT PAGE TRAILER PRINT COLUMN 50, PAGENO USING "Page: <<<<"; ON EVERY ROW CASE (Ctrl) WHEN 1 SKIP TO TOP OF PAGE OTHERWISE PRINT COLUMN 1, Lne CLIPPED END CASE END REPORT -- Dept of Computer Science Internet: stuart@coral.cs.jcu.edu.au James Cook University Townsville Tel: +61 77 814992 Qld 4811 Australia FAX: +61 77 814029