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

How to replace a value in a file using syncsort


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
dev.vinay

New User


Joined: 20 Sep 2006
Posts: 4
Location: Bangalore

PostPosted: Mon Mar 02, 2009 7:43 am
Reply with quote

Hello,

I have a flat file (FB) recl 2004. I have a header and a detail records.
I have to change the value of the hearder only. I have to change 159th and 160th position. And we use syncsort in our shop.

Please help.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Mon Mar 02, 2009 7:50 am
Reply with quote

Hello,

How is a header known from a detail? What is the recfm? Do you want to change "from" some particular value "to" some other or do you want to change all of the headers to the same "to" value?

What release of Syncsort is used on the system?
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Mon Mar 02, 2009 10:48 am
Reply with quote

Hi,

In addition to what Dick has asked - it's always good to show a bit of your input, rules & the expected output for such questions. . .
Back to top
View user's profile Send private message
Abhushan_s

New User


Joined: 28 Jul 2008
Posts: 34
Location: Ahmedabad

PostPosted: Mon Mar 02, 2009 3:50 pm
Reply with quote

First of all the header would be just a single record in the file so you could just change it manually as the change is only for 2 bytes from FILE-AID if you know the value that would be move to those 2 positions. icon_confused.gif

And if thats not the case

Quote:
I have to change the value of the hearder only


Just check how is a header identified in the file, and then based on it use a SORT condition first which should only filter out the header, after that you could use OUTREC function that would allow you to change the value at that particular position in the header.
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
Search our Forums:

Back to Top