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
 

 

splitting the comp-3 field

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
somapradeep1

New User


Joined: 07 Sep 2010
Posts: 22
Location: hyderabad

PostPosted: Fri Apr 20, 2012 8:29 pm    Post subject: splitting the comp-3 field
Reply with quote

hi,

in one of my vsam file one field is zip pic s9(9)comp-3.it contains data as
64570000
764530000
787012698
322380000
320030000
150280000
752010000 my req is i want to copy all fields in o/p file but the zip column should be split in to two columns by spliting which are in bold as a superate column..pls help me
Back to top
View user's profile Send private message

Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7308

PostPosted: Fri Apr 20, 2012 8:53 pm    Post subject: Reply to: splitting the comp-3 field
Reply with quote

This is basically the third time you've asked this recently, twice today.

Here's the other one.

What problem are you having in doing this? Are you no longer using DFSORT?

Code:
  OPTION COPY                                           
  INREC OVERLAY=(tosomewhere:somewherenow,5,PD,TO=ZD,LENGTH=9,
                                  dest1:tosomewhere,5,ZD,TO=PD,LENGTH=3,
                                  dest2:tosomewhere+5,4,ZD,TO=PD,LENGTH=3)


Where

tosomewhere
somewherenow
dest1
dest2
tosomewhere+5

are things that we don't know.

OK, I make them up:

Code:
//PACKED   EXEC PGM=SORT
//SORTIN DD *
123456789
//SYSOUT   DD SYSOUT=*
//SORTOUT DD SYSOUT=*
//SYSIN DD *
  OPTION COPY
  INREC OVERLAY=(10:1,9,ZD,TO=PD,LENGTH=5,20:10,5,PD,TO=ZD,LENGTH=9,
                 30:20,5,ZD,TO=PD,LENGTH=3,
                 40:25,4,ZD,TO=PD,LENGTH=3)



Gives this:

Code:
123456789          123456789   *         
FFFFFFFFF1357944444FFFFFFFFF41354444444079
1234567892468C00000123456789024C000000068C


Now, let me get the kettle on and dust the chair for you...
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Fri Apr 20, 2012 9:32 pm    Post subject: Reply to: splitting the comp-3 field
Reply with quote

Hello,

If you continue posting the same question multiple times, they will be deleted. . . icon_sad.gif

Beyond that, your userid might be Warned or Banned. . .

d
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Splitting of single report to seperat... abdulrafi TSO/ISPF 4 Mon Mar 27, 2017 3:59 pm
No new posts splitting a file abdulrafi DFSORT/ICETOOL 4 Fri Mar 24, 2017 11:51 am
No new posts SORT VSAM file with each field one by... maxsubrat DFSORT/ICETOOL 6 Tue Mar 14, 2017 1:07 pm
No new posts IMS DB-How to update a record (a sing... Nic Clouston IMS DB/DC 9 Thu Mar 09, 2017 4:38 pm
No new posts outrec field outside range Danielle.Filteau SYNCSORT 10 Sat Mar 04, 2017 2:37 am


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