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
 

 

all 16 bytes should contain only values 1 thru 9 or A thru Z

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

New User


Joined: 21 Mar 2005
Posts: 1

PostPosted: Mon Mar 21, 2005 3:48 pm    Post subject: all 16 bytes should contain only values 1 thru 9 or A thru Z
Reply with quote

hi all

i have an input file of record length 16 bytes. Now, the data in these 16 bytes can be any value including the special characters. the requirement is i have to look into these 16 bytes and select only those records that meet the following condition.

cond:
all the 16 bytes should not contain any special character otherwise the 16 bytes should contain only values 1 thru 9 or A thru Z.

OPTION COPY
INCLUDE COND=((10,1,CH,GE,C'1',AND,10,1,CH,LE,C'9'),
OR,(10,1,CH,GE,C'A',AND,10,1,CH,LE,C'Z'))
the above sort card takes care of 1 byte at position 10. but can we extend the same for all 16 bytes....

i know i can do this using a program but i wnat to do it using DFSORT? is it possible?

thanks in advance for ur responces
yesh
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: Mon Mar 21, 2005 9:57 pm    Post subject:
Reply with quote

yesh,

Here's a DFSORT job that will do what you asked for:

Code:

//S1    EXEC  PGM=ICEMAN
//SYMNAMES DD *
check,'123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ'
//SYSOUT    DD  SYSOUT=*
//SORTIN DD DSN=...  input file
//SORTOUT DD DSN=...  output file
//SYSIN    DD    *
  OPTION COPY
  OMIT FORMAT=SS,
      COND=(1,1,NE,check,OR,
            2,1,NE,check,OR,
            3,1,NE,check,OR,
            4,1,NE,check,OR,
            5,1,NE,check,OR,
            6,1,NE,check,OR,
            7,1,NE,check,OR,
            8,1,NE,check,OR,
            9,1,NE,check,OR,
           10,1,NE,check,OR,
           11,1,NE,check,OR,
           12,1,NE,check,OR,
           13,1,NE,check,OR,
           14,1,NE,check,OR,
           15,1,NE,check,OR,
           16,1,NE,check)
/*
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 SQL query to run through list of valu... Ni3-db2 DB2 14 Wed Dec 14, 2016 9:52 am
No new posts Overlaying one set of charater values... Kevin Lindsley SYNCSORT 7 Sat Nov 05, 2016 3:21 am
No new posts Low values Results from VARCHAR FORMAT balaji81_k DB2 10 Thu Oct 20, 2016 1:18 am
No new posts How can we create a flat file in JAVA... rakesh.v18 Java & MQSeries 7 Fri Sep 23, 2016 10:46 pm
No new posts Using 'parm' to vary SORTOUT record v... Sysaron DFSORT/ICETOOL 13 Wed Sep 07, 2016 9:24 pm


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