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
 

 

SYCNCSort Change Command

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

New User


Joined: 02 Feb 2010
Posts: 14
Location: hyderabad

PostPosted: Tue Dec 28, 2010 2:02 pm    Post subject: SYCNCSort Change Command
Reply with quote

Hi,

My input file is having lenght of 40 bytes. Now I would like to know how to
change the values starting form the coloumn 31 based on the coloumn starting from 20,6(position and length).

Here is the example
Input file:
A 202LS372A LSA 202 SPRGA 202 TAMINA TX
A 202LS372A LSE 033 SPRGA 202 TAMINA TX

As per the above file in the second record if the value is E 033 (postion 20)I want to change TAMINA TX to CALIFORNIA TX.

Please let me know how to write this in SYNCSORT.


Thanks,
Rajesh.
Back to top
View user's profile Send private message

Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2233
Location: @my desk

PostPosted: Tue Dec 28, 2010 5:47 pm    Post subject:
Reply with quote

The field positions you mentioned do not seem to match with that of the sample data.
Back to top
View user's profile Send private message
acevedo

Active User


Joined: 11 May 2005
Posts: 344
Location: Spain

PostPosted: Tue Dec 28, 2010 6:18 pm    Post subject:
Reply with quote

I'd use FINDREP

;)
Back to top
View user's profile Send private message
elijarajesh.mf
Warnings : 1

New User


Joined: 02 Feb 2010
Posts: 14
Location: hyderabad

PostPosted: Tue Dec 28, 2010 6:29 pm    Post subject:
Reply with quote

Thank you
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


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

PostPosted: Wed Dec 29, 2010 7:04 pm    Post subject:
Reply with quote

So the problem solved? You didnot tell about the release of SyncSort you are at - however, just for the record, Support for FINDREP was included in SyncSort for z/OS 1.3.2.
Back to top
View user's profile Send private message
Alissa Margulies

SYNCSORT Support


Joined: 25 Jul 2007
Posts: 500
Location: USA

PostPosted: Wed Dec 29, 2010 10:59 pm    Post subject:
Reply with quote

Based on the actual sample data provided, here is one way to accomplish this task:
Code:
//SORT1 EXEC PGM=SORT                                                 
//SORTIN  DD *                                                       
A 202LS372A LSA 202 SPRGA 202 TAMINA TX                               
A 202LS372A LSE 033 SPRGA 202 TAMINA TX                               
//SORTOUT DD SYSOUT=*                                                 
//SYSOUT  DD SYSOUT=*                                                 
//SYSIN   DD *                                                       
 INREC IFTHEN=(WHEN=(17,3,CH,EQ,C'033'),OVERLAY=(31:C'CALIFORNIA TX'))
 SORT FIELDS=COPY                                                     
/*                                                                   

The output produced is as follows:
Code:
A 202LS372A LSA 202 SPRGA 202 TAMINA TX   
A 202LS372A LSE 033 SPRGA 202 CALIFORNIA TX


Regards,
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 TSO or command line utility to genera... kishpra JCL & VSAM 3 Thu Mar 09, 2017 1:11 am
No new posts Customizing the ISPF HILITE Command Pedro TSO/ISPF 3 Fri Mar 03, 2017 11:49 pm
No new posts Fail to change physical VSAM filename... jacobdng CICS 7 Fri Jan 20, 2017 12:36 pm
No new posts What is the command to check MODE of ... rohanthengal CLIST & REXX 7 Fri Nov 18, 2016 1:48 pm
No new posts SDSF Command Avtrix CLIST & REXX 4 Fri Sep 30, 2016 11:13 am


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