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
 

 

Inserting data in to file as comp3

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

Active User


Joined: 18 Oct 2005
Posts: 182
Location: Luton UK

PostPosted: Thu Feb 23, 2006 8:52 pm    Post subject: Inserting data in to file as comp3
Reply with quote

Hi Guys,

My requirement there is file has a record layout has a variable with s9(12) comp3 ,starts from the position from 107 byte, in that file in need to enter the number 988567546732
using outrec control card for all the records in the file..


Please let me know,

Regards
Jai
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: Thu Feb 23, 2006 10:00 pm    Post subject:
Reply with quote

An s9(12) comp3 field is a 7-byte PD field, so 988567546732 would be P'988567546732' (X'0988567546732C'). Here are two ways to do what you asked for with DFSORT:

Code:

//S1    EXEC  PGM=ICEMAN                                         
//SYSOUT    DD  SYSOUT=*                                         
//SORTIN DD DSN=...  input file
//SORTOUT DD DSN=...  output file 
//SYSIN    DD    *                                               
  OPTION COPY                                                     
  INREC OVERLAY=(107:+988567546732,TO=PD,LENGTH=7)               
/*


Code:

//S2    EXEC  PGM=ICEMAN                                         
//SYSOUT    DD  SYSOUT=*                                         
//SORTIN DD DSN=...  input file
//SORTOUT DD DSN=...  output file 
//SYSIN    DD    *                                               
  OPTION COPY                                                     
  INREC OVERLAY=(107:X'0988567546732C')               
/*
Back to top
View user's profile Send private message
rajandhla

Active User


Joined: 18 Oct 2005
Posts: 182
Location: Luton UK

PostPosted: Thu Feb 23, 2006 10:43 pm    Post subject:
Reply with quote

Thanks frank

Regards
jai
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
No new posts Changing of LRECL of a file abdulrafi DFSORT/ICETOOL 1 Fri Mar 24, 2017 3:25 pm
No new posts splitting a file abdulrafi DFSORT/ICETOOL 2 Fri Mar 24, 2017 11:51 am
No new posts Receive a file using PCOMM macro Harald.v.K IBM Tools 0 Thu Mar 23, 2017 6:50 pm
No new posts Export flat file data into excel sheet murali.andaluri DFSORT/ICETOOL 2 Mon Mar 20, 2017 5:39 pm
No new posts Formatting VB File Learncoholic DFSORT/ICETOOL 3 Mon Mar 20, 2017 12:29 pm


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