Page 2 of 2

Re: How to reformat

PostPosted: Fri Aug 16, 2013 6:08 pm
by BillyBoyo
Well, you now need a second WHEN=GROUP.

BEGIN= for you LFILE=, RECORDS=2 and PUSH=(89:16,44)

Then IFTHEN=(WHEN=(test for AFILE),BUILD=(using the data from 81,8 89,44 and 15 for lenth of however long that may be.

There's been a spec-change I see. Have a look at PARSE to get the actual file-name from the full file-name. You may want to look at JFY/SQZ.

Then the OUTFIL OMIT/INCLUDE you should be able to handle.

Re: How to reformat

PostPosted: Fri Aug 16, 2013 8:04 pm
by deva_048
thanks billy.
Finally got to some shape... Now need to remove unwanted rows.. how to omit unwanted lines... i need only 3rd and 6th row

7----+----8----+----9----+----0----+----1----+----2----+----3----+----4----+---
********************************* Top of Data *********************************
JOBDD413                                                                       
JOBDD413  =I00.I0021102.DATA                                                   
JOBDD413  =I00.I0021102.DATA            A.DATA   
JOBDD414  =I00.I0121102.DATA            A.DATA   
JOBDD414  =I01.I0121500.DATA            ADATA   
JOBDD414  =I01.I0121500.DATA            B.DATA

Re: How to reformat

PostPosted: Fri Aug 16, 2013 8:25 pm
by BillyBoyo
Just like INCLUDE/OMIT prior to INREC, there is an INCLUDE/OMIT for OUTFIL which processes output records.

  OUTFIL OMIT=(

  OUTFIL INCLUDE=(

Notice that OUTFIL INCLUDE/OMIT does not have the COND=.

Exactly how you use it, depends on what you've coded and when you've done the formatting.

I don't think you've done your formatting conditionally. I would do that, so you only reformat the third record. You could then set the position where JOB is to blanks, using IFTHEN=(WHEN=NONE, says "if none of the IFTHEN=(WHEN=(logical expression) are true, do this".

Then on OUTFIL OMIT=(position of the string JOB,3,CH,EQ,C' ')

Try something like that and then show us the Control Cards you have, and any remaining issues.