What about having the program that prints the report also produce a side file 
containing XML?  Howard's COBOL report reader would process the XML file 
instead of the "printed report".  (COBOL can process XML, after all.)  
 
 
On Mon, 10 Sep 2007 10:36:46 -0700, Ulrich Krueger wrote:

>Howard,
>Instead of trying to read in a "printed report" on file and parsing my way
>through all the extraneous stuff like page heading lines, total lines, blank
>lines etc. to get to the meat of the information, I would ask for the input
>file that created the report in the first place. Processing a data file is,
>IMHO, a lot less error prone than parsing my way through a printed report.
>OK, it can be done and I have done it, too, if I had no other choice. But I
>prefer not to do so. And you can bet money on the fact that a few months or
>years later, the report format changes because someone modified the report
>program and then your program goes down in flames ... that's probably going
>to cause a 3am phone call from a panicked operator ... I like to avoid that
>kind of disturbances.  
>
>Alternatively, if you cannot process the input file, for whatever the
>reason, try and see if you can get a data file containing the needed
>information. Change (or have someone change) the report program to also
>output a data file with the information that you are looking for and then
>process that data file instead of the "printed report" file.
>
>Regards,
>Ulrich Krueger
>
>-----Original Message-----
>From: IBM Mainframe Discussion List On Behalf Of Howard Brazee
>Sent: Monday, September 10, 2007 09:46
>Subject: How would you read a report?
>
>What would be the cleanest way to have a CoBOL program read a report file
>
>//             DCB=(RECFM=FB,LRECL=133,DSORG=PS)
>
>Would you copy it first, changing its format?
 
-- 
Tom Schmidt 
Madison, WI

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to