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
 

 

User Abend 0016 occurs in Sort JCL

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

New User


Joined: 23 Aug 2006
Posts: 93
Location: chennai

PostPosted: Thu May 10, 2007 7:15 pm    Post subject: User Abend 0016 occurs in Sort JCL
Reply with quote

Hi All,
See the below code , SORT abend occurs due to split in the value mention in the cond column. Can any one help me to solve this problem?


INCLUDE COND=(1032,3,EQ,C'3CR',AND,9,3,EQ,C'AGE,ARX,ATE,AUG,
A5D,A75,N4Q,YCM,0BA,118,5YV,3CR'),FORMAT=SS
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Thu May 10, 2007 7:24 pm    Post subject:
Reply with quote

Please post the output from your job which clearly shows the error and the associated error message, i.e. ICE.... or WER...

This will help people to help you.
Back to top
View user's profile Send private message
cpuhawg

Active User


Joined: 14 Jun 2006
Posts: 331
Location: Jacksonville, FL

PostPosted: Thu May 10, 2007 7:24 pm    Post subject: Re: User Abend 0016 occurs in Sort JCL
Reply with quote

This should also work:

Code:

INCLUDE COND=((1032,3,EQ,C'3CR'),AND,
     (9,3,EQ,C'AGE,ARX,ATE,AUG,A5D,A75,N4Q,YCM,0BA,118,5YV,3CR')),
      FORMAT=SS
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: Thu May 10, 2007 7:25 pm    Post subject: Re: User Abend 0016 occurs in Sort JCL
Reply with quote

Aren't there some AND or OR statements missing?
Back to top
View user's profile Send private message
cpuhawg

Active User


Joined: 14 Jun 2006
Posts: 331
Location: Jacksonville, FL

PostPosted: Thu May 10, 2007 7:44 pm    Post subject: Re: User Abend 0016 occurs in Sort JCL
Reply with quote

You are correct. Multiple OR's work for FILEAID, but not for SORT:

Code:

INCLUDE COND=((1032,3,CH,EQ,C'3CR'),AND,
     (9,3,CH,EQ,C'AGE',OR,
     (9,3,CH,EQ,C'ARX',OR,
     (9,3,CH,EQ,C'ATE',OR,
     (9,3,CH,EQ,C'AUG',OR,
     (9,3,CH,EQ,C'A5D',OR,
     (9,3,CH,EQ,C'A75',OR,
     (9,3,CH,EQ,C'N4Q',OR,
     (9,3,CH,EQ,C'YCM',OR,
     (9,3,CH,EQ,C'0BA',OR,
     (9,3,CH,EQ,C'118',OR,
     (9,3,CH,EQ,C'5YV',OR,
     (9,3,CH,EQ,C'3CR')),
      FORMAT=SS 
Back to top
View user's profile Send private message
cpuhawg

Active User


Joined: 14 Jun 2006
Posts: 331
Location: Jacksonville, FL

PostPosted: Thu May 10, 2007 7:51 pm    Post subject: Re: User Abend 0016 occurs in Sort JCL
Reply with quote

Too many left parenthesis.....

Code:

INCLUDE COND=((1032,3,CH,EQ,C'3CR'),AND,
    (9,3,CH,EQ,C'AGE',OR,
     9,3,CH,EQ,C'ARX',OR,
     9,3,CH,EQ,C'ATE',OR,
     9,3,CH,EQ,C'AUG',OR,
     9,3,CH,EQ,C'A5D',OR,
     9,3,CH,EQ,C'A75',OR,
     9,3,CH,EQ,C'N4Q',OR,
     9,3,CH,EQ,C'YCM',OR,
     9,3,CH,EQ,C'0BA',OR,
     9,3,CH,EQ,C'118',OR,
     9,3,CH,EQ,C'5YV',OR,
     9,3,CH,EQ,C'3CR')),
      FORMAT=SS 
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Thu May 10, 2007 7:54 pm    Post subject:
Reply with quote

I must admit that I initially thought that, but somewhere in the back of my mind I sort of recalled something about multiple search options.

Quote:
Find a field value within a constant. For example, you can search the character constant C'J69,L92,J82' for the value in a 3-byte field. If the field value is C'J69', C'L92', or C'J82', the relational condition is true; if the field value is C'X24', the relational condition is false. Note that the comma is used within the constant to separate the valid 3-character values; any character that will not appear in the field value can be used as a separator in the constant.


But the way I understand this, is that you can specify multiple options to be searched for in one place, rather than multiple OR statements.
Back to top
View user's profile Send private message
Phrzby Phil

Active Member


Joined: 31 Oct 2006
Posts: 962
Location: Richmond, Virginia

PostPosted: Thu May 10, 2007 8:00 pm    Post subject:
Reply with quote

Does FORMAT=SS work for all mainframe SORT programs?
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Thu May 10, 2007 8:09 pm    Post subject:
Reply with quote

Certainly does for DFSORT
Back to top
View user's profile Send private message
ramfrom84

New User


Joined: 23 Aug 2006
Posts: 93
Location: chennai

PostPosted: Thu May 10, 2007 8:13 pm    Post subject: Re: User Abend 0016 occurs in Sort JCL
Reply with quote

This is my ABEND Message

Code:
 SYSIN :                                                               
  SORT FIELDS=COPY                                                     
  INCLUDE COND=(1032,3,EQ,C'3CR',AND,9,3,EQ,C'AGE,ARX,ATE,AUG,A5D,A75,*
                        *                                               
                A5D,A75,N4Q,YCM,0BA,118,5YV,3CR'),FORMAT=SS             
                *                                                       
 WER251A  INCLUDE/OMIT INVALID FORMAT                                   
 WER275A  NO KEYWORDS FOUND ON CONTROL STATEMENT                       
 WER211B  SYNCSMF  CALLED BY SYNCSORT; RC=0000                         
 WER449I  SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE                         


we did not give as separately since it has 800 value in the cond caluse, we have some 8000 OR statements. Please suggest me to give in the single line.

Thanks for ur interest
Back to top
View user's profile Send private message
dick scherrer

Site Director


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

PostPosted: Thu May 10, 2007 8:49 pm    Post subject:
Reply with quote

Hello,

You are using Syncsort - many DFSORT options either do not exist or have different syntax in Syncsort.

Are you sure that you can use 8000 OR statements?

If i've time later, i'll look, but in the meantime, you might want to refer to the Syncsort manual.

Sounds like a bit of code would be done quickly. . .
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Fri May 11, 2007 12:18 pm    Post subject:
Reply with quote

Sounds like a job for a SELECT clause, but there again that's for DFSORT.

Or, you could code multiple OR statements, each one on a new line.
Back to top
View user's profile Send private message
dick scherrer

Site Director


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

PostPosted: Sat May 12, 2007 4:07 am    Post subject:
Reply with quote

Hello,

You can do the kind of thing you want with INCLUDE and OR in Synsort.

I've not been able to find the limit on the number of ORs you may use in a single execution. I suspect it is below 8000.

If this was my requirement, i'd read the 8000 values into an array (making sure the values were in sequence) then read the input data file and do a binary search on the 8000 entry array. I'd keep the records i want and skip the others. As time goes by, the list of values could be updated, but no code would need to change as nothing would be hard-coded.
Back to top
View user's profile Send private message
ksreddy

New User


Joined: 30 Mar 2005
Posts: 12
Location: Hyderabad

PostPosted: Mon May 14, 2007 10:39 am    Post subject:
Reply with quote

Hi ram,

Use the control statements given by cpuhawg.
It should work for syncsort.

Your error message clearly tells that it was a continuation error.
Back to top
View user's profile Send private message
subratghose

New User


Joined: 06 Dec 2006
Posts: 4
Location: India

PostPosted: Thu Sep 25, 2008 1:08 pm    Post subject: Reply to: User Abend 0016 occurs in Sort JCL
Reply with quote

Have you tried giving FORMAT=SS at beginning like,

SORT FIELDS=COPY
INCLUDE FORMAT=SS,
COND=(1,700,EQ,C'TSO 08CW2CT7B97',OR, ............
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


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

PostPosted: Thu Sep 25, 2008 1:43 pm    Post subject:
Reply with quote

Hi Subrat,

Hopefully you've noticed the date of last post of this thread, just before your post. If you will search around you will found there are many other live discussons going on, you'll enjoy there rather.. icon_smile.gif
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 Innovations in Your Mainframe Sort Arun Raj PC Guides & IT News 4 Wed Mar 15, 2017 10:38 pm
No new posts SORT VSAM file with each field one by... maxsubrat DFSORT/ICETOOL 6 Tue Mar 14, 2017 1:07 pm
No new posts SORT requirement sjiraga COBOL Programming 6 Thu Mar 09, 2017 9:11 pm
No new posts SORT to append Month and YEAR in MMYY... tisamf DFSORT/ICETOOL 1 Wed Mar 08, 2017 4:46 pm
No new posts IMS region inactive - User abend code... gthmrj IMS DB/DC 5 Tue Mar 07, 2017 12:29 pm


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