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
 

 

Eliminate Non-Numeric data from POS 4 till 11

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

New User


Joined: 02 Sep 2005
Posts: 26
Location: Hyderabad

PostPosted: Thu Aug 23, 2007 1:31 pm    Post subject: Eliminate Non-Numeric data from POS 4 till 11
Reply with quote

Hi all,

Code:

//PS0100   EXEC PGM=ICEMAN                                   
//*--------------------------------------------               
//SYSOUT   DD  SYSOUT=*                                       
//SYSPRINT DD  SYSOUT=*                                       
//SYSUDUMP DD  SYSOUT=*                                       
//SORTIN   DD DISP=SHR,DSN=XXXX.XXX.abc
//OUT1     DD DSN=XXXX.XXX.abc.sortout,         
//         DISP=(NEW,CATLG,DELETE),                           
//         UNIT=(SYSALLDA,30),SPACE=(CYL,1),                 
//         LRECL=3080,RECFM=FB,BLKSIZE=0                     
//SYSIN    DD *                                               
    OPTION COPY                                               
    OUTFIL INCLUDE COND=(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',                     
                      AND,7,1,CH,GE,C'0',         
AND,7,1,CH,LE,C'9',               
AND,8,1,CH,GE,C'0',               
AND,8,1,CH,LE,C'9',               
AND,9,1,CH,GE,C'0',               
AND,9,1,CH,LE,C'9',               
AND,10,1,CH,GE,C'0',             
AND,10,1,CH,LE,C'9',             
AND,11,1,CH,GE,C'0',             
AND,11,1,CH,LE,C'9',             
AND,12,1,CH,GE,C'0',             
AND,12,1,CH,LE,C'9'),FNAMES=OUT1 
/*


In the input file pos 4 to 11 has non-numeric values. Need to eliminate this... This job is getting abended...OUTFIL STATEMENT : SYNTAX ERROR..
Cld anyone help?

Thanks!
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 Aug 23, 2007 8:46 pm    Post subject:
Reply with quote

Here's a DFSORT job that will eliminate records with non-numeric data in positions 4-11:

Code:

//PS0100   EXEC PGM=ICEMAN
//SYSOUT   DD  SYSOUT=*
//SYSUDUMP DD  SYSOUT=*
//SORTIN   DD DSN=...   input file
//SORTOUT  DD DSN=...  output file
//SYSIN    DD *
  OPTION COPY
  INCLUDE COND=(4,8,FS,EQ,NUM)
/*


Quote:
This job is getting abended...OUTFIL STATEMENT : SYNTAX ERROR..


Yes, because you have syntax errors.

Code:

    OUTFIL INCLUDE COND=(4,1,CH,GE,C'0',


should be:

Code:

    OUTFIL INCLUDE=(4,1,CH,GE,C'0',


The lines starting with:

Code:

AND,7,1,CH,LE,C'9',


should have at least one blank before the AND, that is, they should start in column 2 or higher.

Also, you say you want to check for non-numeric values in 4-11 but then you have conditions for position 12 which you shouldn't.
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 Storing huge volume of data, compare ... Pradeep K M All Other Mainframe Topics 3 Mon Jan 16, 2017 5:08 pm
No new posts how to recover an uncataloged VSAM da... archanamuthukrishnan All Other Mainframe Topics 3 Wed Jan 11, 2017 6:18 pm
No new posts HALDB data refresh/copy from producti... vineetanand2007 IMS DB/DC 1 Mon Jan 02, 2017 11:16 am
No new posts JES2 JEC: Use UNIX Pipes to Pass Data... Virendra Shambharkar JCL & VSAM 21 Tue Dec 20, 2016 6:55 pm
No new posts Is the 'prompt' data for the DSLIST p... Willy Jensen TSO/ISPF 2 Tue Dec 06, 2016 4:38 am


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