IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

How covert VB to FB while using PARSE in INREC statement.


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
rguhanath

New User


Joined: 16 Oct 2006
Posts: 81
Location: chennai

PostPosted: Sat May 17, 2008 4:57 pm
Reply with quote

Hi All,

i have a requirement like i have two files one is input file(VB format, have length 458) and i need to adjust the fields in the records using PARSE in INREC statement like below(for example). while doing this i want the output file in FB format with length 454.

Example ( taken from previous scraps...)
Code:

//S1    EXEC  PGM=ICEMAN
//SYSOUT    DD  SYSOUT=*
//SORTIN DD DSN=...  input file (FB)
//SORTOUT DD DSN=...  output file (FB)
//SYSIN    DD    *
  OPTION COPY
  INREC PARSE=(%00=(ENDBEFR=C';',FIXLEN=10),
               %01=(ENDBEFR=C';',FIXLEN=10),
               %02=(FIXLEN=10)),
        BUILD=(1:%00,25:%01,41:%02,JFY=(SHIFT=RIGHT))
/*



in the above example it shows from FB to FB, but i want VB to FB with using above code. please help me.

Regards,
Nath R.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Sat May 17, 2008 8:46 pm
Reply with quote

You can use a DFSORT job like the following to do what you asked for:

Code:

//S1    EXEC  PGM=ICEMAN
//SYSOUT    DD  SYSOUT=*
//SORTIN DD DSN=...  input file (VB/458)
//SORTOUT DD DSN=...  output file (FB/454)
//SYSIN    DD    *
  OPTION COPY
  OUTFIL VTOF,
    PARSE=(%00=(ENDBEFR=C';',FIXLEN=10),
           %01=(ENDBEFR=C';',FIXLEN=10),
           %02=(FIXLEN=10)),
    BUILD=(1:%00,25:%01,41:%02,JFY=(SHIFT=RIGHT),454:X)
/*
Back to top
View user's profile Send private message
rguhanath

New User


Joined: 16 Oct 2006
Posts: 81
Location: chennai

PostPosted: Sun May 18, 2008 7:35 pm
Reply with quote

Thanks Frank... its working...

-Nath R
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts PARSE Syntax for not fix length word ... JCL & VSAM 7
No new posts JOIN STATEMENT PERFORMANCE. DFSORT/ICETOOL 12
No new posts Relate COBOL statements to EGL statement All Other Mainframe Topics 0
No new posts INREC PARSE used to sort a CSV file DFSORT/ICETOOL 2
No new posts JSON transform using CICS bundles vs.... CICS 3
Search our Forums:

Back to Top