Focal Point
Define File and Variable Size...

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/6861028371

June 27, 2006, 10:30 AM
Wayne Atchley
Define File and Variable Size...
Question and solicitation for workaround with variable size in a define file.

Assume the following define file statement:

DEFINE FILE CAE_AGENT_PRODUCER
ROWCNT/I9 = LAST ROWCNT + 1;
TABLESTART/A7 = '< TABLE >';
TABLEEND/A8 = '< /TABLE >';
TABLEROW/A4096 = TABLESTART | '< tr > Insert a boatload of code here with td tages and all the formatting ' | TABLEEND;
END

We are doing a lot in the '< tr >' tags... and we are exceeding the A4096 length which seems to be the maximum inside the define file. the testing data we are using produces a report with 13 columns... but our production reports could have up to 30 columns or more.

does anyone know how to get past this limit?

If you need more information, let me know and I will explain the problem further.

Thanks!

Wayne

This message has been edited. Last edited by: Wayne Atchley,
June 27, 2006, 12:33 PM
smiths
Wayne,

Will this sort of idea solve your dilemma? Break your HTML into smaller pieces contained in multiple variables, then print them using OVER.

  
DEFINE FILE CAR
TABLESTART/A25 = '<TABLE BORDER=1>';
HTML1/A1024 = '<TR><TD>' | CAR;
HTML2/A1024  = '</TD></TR>';
TABLEEND/A12 = '</TABLE>';
END

TABLE FILE CAR
PRINT
TABLESTART OVER
HTML1 OVER
HTML2 OVER
TABLEEND 
WHERE COUNTRY EQ 'ENGLAND'
ON TABLE HOLD AS HOLDHTML
END


-HTMLFORM BEGIN
!IBI.FIL.HOLDHTML;
-HTMLFORM END



------------------------------------------------------------------------
PROD: WebFOCUS 7.6.2 on Unix AIX/Tomcat/Servlet Mode
TEST: WebFOCUS 7.6.2 on Unix AIX/Tomcat/Servlet Mode
June 27, 2006, 12:55 PM
Wayne Atchley
We tried that, but when we view the generated HTML it pads the data with spaces on the print... so the HTML stuff comes out fine, but the data field (actual column in the database) comes out padded and that messes up our output.

But on the plus side, we learned a new command that we can use later. Thanks!

WA
June 27, 2006, 01:08 PM
susannah
Wayne,
try using less formatting code in your td tags, just class names, and then in your output area, define your classes.
-HTMLFORM BEGIN
<HTML>
<HEAD>
<style>
td.one{ all the style attributes youwant}
td.two { more styleattributes for class two}
...etcetera
</style>
</HEAD>
<BODY>
!IBI.FIL.MYTABLE1;
!IBI.FIL.MYTABLE2; ifyou have more than 1 table
etc..whatever you have
</BODY>
</HTML>
-HTMLFORM END

We take for granted that you're absolutely sure that regular webfocus tables with boatloads of conditional styling wont work for you , for some reason.

This message has been edited. Last edited by: susannah,




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
June 27, 2006, 04:18 PM
Wayne Atchley
Thanks susannah... this is an approach we are considering. It just means we have to re-write a lot of the code we have already worked on...

Currently, our fex has over 1000 lines and only 80 is FOCUS... the rest is HTML and javascript. So, we are busy working through the problems.

Again, I appreciate the insights.

Wayne