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
 

 

Sort hex Decimal field with in Array range

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

New User


Joined: 11 Dec 2007
Posts: 26
Location: INDIA

PostPosted: Thu Jun 17, 2010 5:44 pm    Post subject: Sort hex Decimal field with in Array range
Reply with quote

Hi,
I have a requirement where I need to filter all records which has HEX Value with in Range 224 to 275.

i have designed the below sort card for it
INCLUDE COND=((224,1,CH,EQ,X'15') OR (225,1,CH,EQ,X'15') OR (226,1,CH,EQ,X'15') OR .... (275,1,CH,EQ,X'15'))

but to my customer this is not acceptable.

Thank You.
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 Jun 17, 2010 5:51 pm    Post subject:
Reply with quote

OK, so what is acceptable to your customer.
Is it the use of sort that is unacceptable, or the way in which your sort statements are coded.
Can you please explain exactly what it is that you are trying to achieve using the sort product.

From what you have shown it looks as though you want to include any record that has a X'15' value anywhere between colums 224 and 275. Is this correct.

Because the solution for sort related questions may vary from product to product, please ensure that you state clearly which sort product you are using.

If you are not sure, then by running a simple sort step shown below, you will be able to find out for yourself.

If the messages start with ICE then your product is DFSORT. Please also post the output of the complete line which has a message code ICE201I, as this will enable our DFSORT experts to determine which release of DFSORT that you have installed. This may also affect the solution offered.

If the messages start with WER or SYT then the product is SYNCSORT and the topic will be moved into the JCL forum by one of the moderators. Please also post the information telling which version of SYNCSORT is installed, as this may also affect the solution offered.

Thank you for taking your time to ensure that the valuable time of others is not wasted by offering inappropriate solutions which are not relevant due to the sort product being used and/or the release that is installed in your site.

Code:
//SORTSTEP EXEC PGM=SORT
//SYSOUT   DD SYSOUT=*
//SORTIN   DD *
ABC
//SORTOUT  DD SYSOUT=*
//SYSIN    DD *
  SORT     FIELDS=COPY
Back to top
View user's profile Send private message
harsh singh

New User


Joined: 11 Dec 2007
Posts: 26
Location: INDIA

PostPosted: Thu Jun 17, 2010 6:00 pm    Post subject:
Reply with quote

The way i have coded the sort statement is unaccpetable as here i am using 50 OR CONDITIONS for checking between 224 to 275 position.

According to my customer code looks bulky and is inefficient.

Yes your understanding is correct , I want to drop any record between 224 to 275 where X15 lies.

Thank You your quick turn around.
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 Jun 17, 2010 6:04 pm    Post subject:
Reply with quote

Using the substring function which will include any record which has X'15' anywhere between colums 224 and 275.
Code:
 INCLUDE COND=(224,52,SS,EQ,X'15')

As your code shows INCLUDE but you last said DROP - if it is DROP, then change INCLUDE for OMIT.
Back to top
View user's profile Send private message
harsh singh

New User


Joined: 11 Dec 2007
Posts: 26
Location: INDIA

PostPosted: Thu Jun 17, 2010 7:42 pm    Post subject:
Reply with quote

Thank You for your response, it has fulfilled my expectations.
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 INVALID FIELD OR CONSTANT IN SORTOF ?? Ron Klop DFSORT/ICETOOL 8 Wed Jan 11, 2017 3:44 pm
No new posts Performing arithmetic on input field zh_lad DFSORT/ICETOOL 31 Tue Dec 06, 2016 8:04 pm
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts Limit duplicate records in the SORT pshongal SYNCSORT 6 Mon Nov 21, 2016 12:54 pm
No new posts How to convert the VBM file to VB or... Sulabh Agrawal JCL & VSAM 4 Fri Nov 18, 2016 1:04 pm


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