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
 

 

Merge fileds Error: Out of sequence in sortin02

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

New User


Joined: 08 Jul 2005
Posts: 1

PostPosted: Fri Jul 08, 2005 12:02 pm    Post subject: Merge fileds Error: Out of sequence in sortin02
Reply with quote

im trying to merge three ps files

when i submit the job i get an error as

out of sequence in sortin02 or

out of sequence in sortin03

i tried to make the contents of the files in the ascending order

even then im getting the same error.

im also not sure about the sysntax of the merge fields

suggest me a merge field with parameters

here's the job
Code:


//U117557$ JOB MSGCLASS=X,MSGLEVEL=(1,1),CLASS=B,
//         REGION=5M,NOTIFY=&SYSUID             
//STEP1     EXEC PGM=SORT                       
//SYSPRINT  DD SYSOUT=*                         
//SYSOUT    DD SYSOUT=*                         
//SORTIN01  DD DSN=U117557.TRAIN.IN1,DISP=SHR   
//SORTIN02  DD DSN=U117557.TRAIN.IN2,DISP=SHR   
//SORTIN03  DD DSN=U117557.TRAIN.IN3,DISP=SHR   
//SORTOUT   DD DSN=U117557.TRAIN.OUT1,DISP=SHR   
//SYSIN     DD *                                 
          MERGE FIELDS=(12,3,A,6,5,A),FORMAT=CH 
/*                                               


im getting a maxcc=16


the contents of the ps files are as follows

1)U117557.TRAIN.IN1

arun
pradeep
push

2)U117557.TRAIN.IN2

dnarmatha
esanu
fkutti
gmathan


3)U117557.TRAIN.IN3

aganeshram
bdinesh
cindia
Back to top
View user's profile Send private message

somasundaran_k

Active User


Joined: 03 Jun 2003
Posts: 134

PostPosted: Fri Jul 08, 2005 7:25 pm    Post subject:
Reply with quote

If the input files are not sorted you may get this error. MERGE expects the files to be in the presorted order. Try to sort these files before merging them.

hth
-Som
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Fri Jul 08, 2005 7:42 pm    Post subject: Re: merge fileds
Reply with quote

I don't understand your MERGE statement:

MERGE FIELDS=(12,3,A,6,5,A),FORMAT=CH

The data you show appears to be characters, starting in column 1 for a length of 10. Why is your MERGE statement not defined as:

MERGE FIELDS=(1,10,A),FORMAT=CH

which would give you this output:

aganeshram
arun
bdinesh
cindia
dnarmatha
esanu
fkutti
gmathan
pradeep
push
Back to top
View user's profile Send private message
bagieswari

New User


Joined: 03 Apr 2004
Posts: 1

PostPosted: Mon Jul 18, 2005 5:24 pm    Post subject: Re: merge fileds
Reply with quote

This is the general syntax of the MERGE field.

MERGE FIELDS=(Positionofthefield, Lengthfromtheposition, Ascending/Descending,FORMAT)
Supposing if u want to merge files first on one field, later on another field u'll repeat the same.

And ur merge field says,
U r going to merge the files based
on the field which start at 12th pos, and length 3 and in ascending order.
Then on the field at 6th position and length five.
But in the inputs u have given there is nothing starting at 12th pos
MERGE FIELDS=(12,3,A,6,5,A),FORMAT=CH

Try this

MERGE FIELDS=(1,2,A,CH)
Back to top
View user's profile Send private message
shobam

New User


Joined: 18 Jul 2005
Posts: 34
Location: CN

PostPosted: Mon Jul 18, 2005 6:04 pm    Post subject:
Reply with quote

Try Sorting each input file with the following option

Code:

  SORT FIELDS=(12,3,A,6,5,A),FORMAT=CH


and merge the sorted files with

Code:

  MERGE FIELDS=(12,3,A,6,5,A),FORMAT=CH


Hope this will work.
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 OO COBOL compile error Virendra Shambharkar COBOL Programming 3 Tue Jan 10, 2017 6:05 pm
No new posts S922 Error yuvan ABENDS & Debugging 3 Fri Dec 02, 2016 6:58 pm
No new posts Invoke Webservice Fails with DFHPI100... divated CICS 2 Thu Nov 24, 2016 5:57 pm
No new posts Error during restore rename archanamuthukrishnan All Other Mainframe Topics 2 Fri Oct 14, 2016 3:30 pm
No new posts Error IEC161I 052(009,XXXRS00)-084 wh... amitc23 JCL & VSAM 10 Wed Oct 12, 2016 5:00 pm


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