Exclude the records based on space.

IBM's Sort Product, ICETOOL, ICEMAN and ICEGENER.
Post Reply
Shriram
Registered Member
Posts: 21
Joined: Fri Aug 16, 2013 3:13 pm

Exclude the records based on space.

Post by Shriram »

Hi,

I have an alpha-numeric field with length 6. The values this field can take are:

Code: Select all

"     " (All Spaces)

Code: Select all

"xy   " (3 Spaces)

Code: Select all

"xyz  " (2 Spaces)
If there is a space in the field, I need to remove such records from input. I am using this sort card. 20 is the starting posistion:

Code: Select all

OMIT COND = (20,6,CH,EQ,C' '),OR,(22,3,CH,EQ,C' '),OR, (23,2,CH,EQ,C' '))
In this I have used multiple ORs. Can this be written in a better way. For example, if the filed is more than 20 characters, then writing so many ORs will make look ugly. Any guidance in this regard wil lbe very nice.
nicc
Global Moderator
Global Moderator
Posts: 691
Joined: Wed Apr 23, 2014 8:45 pm

Re: Exclude the records based on space.

Post by nicc »

Try reading up on String Search (SS) in the manual.
Regards
Nic
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “IBM DFSort, ICETOOL, ICEMAN, ICEGENER.”