Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Can I use DF Sort for VSAM file.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
Huan-Nguyen

New User


Joined: 17 Jan 2006
Posts: 17

PostPosted: Tue Jan 17, 2006 8:03 am    Post subject: Can I use DF Sort for VSAM file.
Reply with quote

Hi,

I have a VSAM file , lenght of record around 200 bytes , In position such as 50 till 54 that contain spaces. Can I use DF Sort to change the position (50-54) from spaces to zeroes binary (X'00000000') for all records in that VSAM file ? Thanks,
Back to top
View user's profile Send private message

MGIndaco

Active User


Joined: 10 Mar 2005
Posts: 432
Location: Milan, Italy

PostPosted: Tue Jan 17, 2006 5:03 pm    Post subject:
Reply with quote

Yes you can using altseq function. Try to search about it in this forum!
I suggest you to do it from vsam to seq.
I hope in this help.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


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

PostPosted: Tue Jan 17, 2006 9:19 pm    Post subject:
Reply with quote

It's NOT a good idea to use the same file for input and output. It would be better to use another VSAM file for output or use an intermediate file for output and then copy that file back to the original VSAM file. For example:

Code:

//S1 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN DD DSN=....  VSAM file
//T1 DD DSN=&&T1,UNIT=SYSDA,SPACE=(CYL,(5,5)),DISP=(,PASS)
//OUT DD DSN=...  VSAM file
//TOOLIN DD *
COPY FROM(IN) TO(T1) VSAMTYPE(F) USING(CTL1)
COPY FROM(T1) TO(OUT)
/*
//CTL1CNTL DD *
   OUTREC OVERLAY=(50:5Z)
/*


50:5Z gives you 5 binary zeros in 50-54.
Back to top
View user's profile Send private message
Huan-Nguyen

New User


Joined: 17 Jan 2006
Posts: 17

PostPosted: Wed Jan 18, 2006 7:05 am    Post subject:
Reply with quote

To MGIndaco : Thanks, I did it , but I would like to find a new way using DFSORT to update in place Vsam file .

To Frank : Your idea is great, thank you very much for help me out . Many thanks to both of you !!! icon_biggrin.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. Fetching data from BAI File arunsoods JCL & VSAM 1 Wed Jul 19, 2017 4:28 pm
No new posts Write out NODUPS but just from one file Jay Villaverde DFSORT/ICETOOL 8 Fri Jul 14, 2017 12:44 am
No new posts SORT to unpack a feild shr_amar DFSORT/ICETOOL 7 Fri Jul 07, 2017 4:32 am
No new posts How to add header with Date(YYMMDD) i... Rajan Moorthy DFSORT/ICETOOL 2 Thu Jul 06, 2017 11:44 pm
No new posts How to write Specific Fields from Mul... Padhu SYNCSORT 6 Thu Jul 06, 2017 10:26 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us