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

Append Zeroes with effecting alphabet data


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

New User


Joined: 21 Mar 2007
Posts: 38
Location: US

PostPosted: Thu Aug 28, 2008 10:28 pm
Reply with quote

Hi,

I have below data in my i/p file:

Code:

SAV0000000010470615
INV000000000000W86348368
INV00000W86348368
AID000062970611910610423


Expected o/p:
Code:

SAV000000000000000000000010470615
INV000000000000000000000W86348368
INV000000000000000000000W86348368
AID000000000000062970611910610423


I have used the below sort card:

SORT FIELDS=COPY
OPTION COPY
INREC BUILD=(1,19,20,30,UFF,M11,LENGTH=30)

This is washing out the alphabets i have in between.

Can anyone help how to get the above o/p. I want to have field from position 20 pre-appended with ZEROES and make it 30 byte field.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


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

PostPosted: Thu Aug 28, 2008 10:40 pm
Reply with quote

Here's a DFSORT job that will do what I think you asked for. Your description of your data doesn't really match the input example you showed, so I guessed what you meant (see //SORTIN below). At any rate, you can't use UFF here because your values are not all numeric. But JFY and TRAN=ALTSEQ will do the trick.

Code:

//S1    EXEC  PGM=ICEMAN                             
//SYSOUT    DD  SYSOUT=*                             
//SORTIN DD *                                       
SAV                0000000010470615                 
INV                000000000000W86348368             
INV                00000W86348368                   
AID                000062970611910610423             
//SORTOUT DD SYSOUT=*                               
//SYSIN    DD    *                                   
  OPTION COPY                                       
  ALTSEQ CODE=(40F0)                                 
  INREC OVERLAY=(20:20,30,JFY=(SHIFT=RIGHT),         
    20:20,30,TRAN=ALTSEQ)                           


SORTOUT would have:

Code:

SAV                000000000000000000000010470615 
INV                000000000000000000000W86348368 
INV                000000000000000000000W86348368 
AID                000000000000062970611910610423 


If I guessed wrong about what your input records look like, show what they do look like or describe them better.
Back to top
View user's profile Send private message
gprerna

New User


Joined: 21 Mar 2007
Posts: 38
Location: US

PostPosted: Thu Aug 28, 2008 10:51 pm
Reply with quote

Getting below error:


Code:

  OPTION COPY                                                   
  ALTSEQ CODE=(40F0)                                             
  INREC OVERLAY=(20:20,30,JFY=(SHIFT=RIGHT),20:20,30,TRAN=ALTSEQ)
                          *                                     
WER268A  INREC STATEMENT   : SYNTAX ERROR                       
WER211B  SYNCSMF  CALLED BY SYNCSORT; RC=0000                   
WER449I  SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE                   



Here is the input file with positions:

Code:

----+----1----+----2----+----3----+----4----+----
***************************** Top of Data *******
55356298077201  CCA000074923014073187           
40011503116201  CCA0074923014165306             
40070535931201  CCA0000000ABC23014193209         
35027190403201  CCA74923014194546               


and expected output is:

Code:

----+----1----+----2----+----3----+----4----+----
***************************** Top of Data *******
55356298077201  CCA00000000000000074923014073187
40011503116201  CCA00000000000000074923014165306
40070535931201  CCA000000000000000ABC23014193209
35027190403201  CCA00000000000000074923014194546
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


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

PostPosted: Thu Aug 28, 2008 10:59 pm
Reply with quote

The job works fine with DFSORT which has had the JFY function since April, 2006. But the WER messages indicate you're using Syncsort, not DFSORT.

I'm a DFSORT developer. DFSORT and Syncsort are competitive products. I'm happy to answer questions on DFSORT and DFSORT's ICETOOL, but I don't answer questions on Syncsort.

You should post Syncsort questions in the JCL Forum, not in the DFSORT Forum. I'm moving this thread over there.
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Thu Aug 28, 2008 11:00 pm
Reply with quote

'WER' shows that you are using SYNCSORT not DFSORT!
Back to top
View user's profile Send private message
gprerna

New User


Joined: 21 Mar 2007
Posts: 38
Location: US

PostPosted: Thu Aug 28, 2008 11:05 pm
Reply with quote

Sorry for that Frank. We dont have DFSORT in our shop.

Can anyone please help to do this using SYNCSORT?
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: Fri Aug 29, 2008 1:50 am
Reply with quote

Hello,

JFY is supported in the current Syncsort release (1.3).

Suggest you talk with your system support to have the current release installed.
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 Data set Rec-Cnt and Byte-Cnt Testing & Performance 2
No new posts SCOPE PENDING option -check data DB2 2
No new posts Check data with Exception Table DB2 0
No new posts JCL EXEC PARM data in C Java & MQSeries 2
This topic is locked: you cannot edit posts or make replies. Automation need help in sorting the data DFSORT/ICETOOL 38
Search our Forums:

Back to Top