Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
OMIT COND to remove non-numeric items while sorting

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

Active User


Joined: 06 Jan 2004
Posts: 247
Location: Hyderabad

PostPosted: Mon Apr 19, 2004 7:40 pm    Post subject: OMIT COND to remove non-numeric items while sorting
Reply with quote

HI all,

By using omit cond can we remove non-numeric items while sorting.

Thanks
Anu
Back to top
View user's profile Send private message

sandip_datta

Active User


Joined: 02 Dec 2003
Posts: 151
Location: Tokyo, Japan

PostPosted: Wed Apr 21, 2004 5:55 am    Post subject:
Reply with quote

Though it is tedious process...I can use INCLUDE condition as below to select Numeric items and omits nonnumeric items -

Code:
 INCLUDE COND=(1,1,CH,GE,C'0',
             AND,1,1,CH,LE,C'9',
             AND,2,1,CH,GE,C'0',
             AND,2,1,CH,LE,C'9',
             AND,3,1,CH,GE,C'0',
             AND,3,1,CH,LE,C'9',
             AND,4,1,CH,GE,C'0',
             AND,4,1,CH,LE,C'9',
             AND,5,1,CH,GE,C'0',
             AND,5,1,CH,LE,C'9',
             AND,6,1,CH,GE,C'0',
             AND,6,1,CH,LE,C'9')
This rather involved INCLUDE statement keeps only

Regards,
Sandip.
Back to top
View user's profile Send private message
bluebird

Active User


Joined: 03 Feb 2004
Posts: 127

PostPosted: Wed Apr 21, 2004 12:28 pm    Post subject:
Reply with quote

hello,

here is a omit statement :
SORT FIELDS=COPY
OMIT COND=(60,4,CH,LE,C'9999')


BUT you should check in the ICETOOL manual to see into the matter.
The link to icetool manual was passed in one of the posts in this thread (by me). So look for it If you don't have this manual.
AND... there goes the link :
http://www.storage.ibm.com/software/sort/mvs/uq90053/pdf/sortpaug.pdf
Back to top
View user's profile Send private message
anuradha

Active User


Joined: 06 Jan 2004
Posts: 247
Location: Hyderabad

PostPosted: Fri Apr 23, 2004 10:05 pm    Post subject: omit cond
Reply with quote

hi bluebird,

i tried with your omit condition.but it didn't work for me.Actually the variable is packed decimal of 17 character length.somehow iam getting spaces in that field and also some values like 0402634517543.tif. so while sorting i thought of removing these kind of records.i tried many ways. sandip suggested some thing using include cond.but that one is very tedious one,which i cant use.

But there is another alternative for me.I skipped those records while reading that file in the program.So my problem is solved.


Just curious.Is there any other alternative thru omit condition to remove non numeric items.For removal of blank line i can give.but for .tif value what can i give.

Thanks
Anu
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


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

PostPosted: Thu Apr 27, 2006 2:42 am    Post subject:
Reply with quote

With z/OS DFSORT V1R5 PTF UK90007 or DFSORT R14 PTF UK90006 (April, 2006), you can use DFSORT's new NUM function to include or omit records based on whether they contain character, packed decimal or zoned decimal numerics or non-numerics. For your example of a 17-byte PD field, you can use this INCLUDE statement (p is the starting position of the PD field):


Code:

   INCLUDE COND=(p,17,PD,EQ,NUM)


or this OMIT statement:

Code:

   OMIT COND=(p,17,PD,NE,NUM)



For complete details of all of the new DFSORT/ICETOOL functions available with the April, 2006 PTFs, see:

www.ibm.com/servers/storage/support/software/sort/mvs/peug/
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 Remove leading spaces from numeric field rexx77 SYNCSORT 6 Wed Sep 06, 2017 2:15 am
No new posts Return a Non Numeric value from REXX Learncoholic CLIST & REXX 3 Fri Sep 01, 2017 8:33 pm
No new posts Sorting on text - but in non-alphabet... Roy Ware SYNCSORT 5 Wed Aug 23, 2017 9:15 pm
No new posts Select numeric portion from CHAR data... balaji81_k DB2 6 Sat Aug 19, 2017 1:51 am
No new posts Validate if a Value from the file is ... balacsv2 COBOL Programming 8 Mon Jun 19, 2017 11:52 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us