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
 
Removing Junk Chareters in a File

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Compuware & Other Tools
View previous topic :: :: View next topic  
Author Message
Anbutheone

New User


Joined: 08 Oct 2008
Posts: 15
Location: Bangalore

PostPosted: Thu Oct 28, 2010 10:36 am    Post subject: Removing Junk Chareters in a File
Reply with quote

Hi All,

I have a requirement to copy a file after replacing all the jink charecters present in the file.

We came to a conclusion that anything less than hex value X'40' is junk. and if any field contains such data, the next step in our job is abending.

So we want to replace all the fields with the value less than x'40' to spaces (X'40').

Is there any way to do it otherthan adding a COBOL program?

i checked in FileAid, but in this, itseems we cannot replace a charecter unless if we know the exact position or the exact value.

Thanks in advance.
Back to top
View user's profile Send private message

gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Oct 28, 2010 3:01 pm    Post subject:
Reply with quote

Hi,

here is a FILEAID that will do what you asked for
Code:
//STEP0001 EXEC PGM=FILEAID                                             
//SYSPRINT DD SYSOUT=*                                                 
//DD01     DD DSN=input-file                                           
//DD01O    DD DSN=output-file                                           
//SYSIN    DD *                                                         
$$DD01 COPYALL OUT=0,                                                   
 EA=(001,0,X'3F,3E,3D,3C,3B,3A,39,38,37,36,35,34,33,32,31,30',X'40'),   
 EA=(001,0,X'2F,2E,2D,2C,2B,2A,29,28,27,26,25,24,23,22,21,20',X'40'),   
 EA=(001,0,X'1F,1E,1D,1C,1B,1A,19,18,17,16,15,14,13,12,11,10',X'40'),   
 EA=(001,0,X'0F,0E,0D,0C,0B,0A,09,08,07,06,05,04,03,02,01,00',X'40')   
//*                                                                     


Gerry
Back to top
View user's profile Send private message
Anbutheone

New User


Joined: 08 Oct 2008
Posts: 15
Location: Bangalore

PostPosted: Thu Oct 28, 2010 3:04 pm    Post subject:
Reply with quote

Thanks Gerry.

I will try this.
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 -> Compuware & Other Tools All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Execute JCL step based on the content... sprikitik JCL & VSAM 2 Tue Oct 03, 2017 10:03 am
This topic is locked: you cannot edit posts or make replies. PS file data should be passed as symb... d_sarlie JCL & VSAM 15 Tue Oct 03, 2017 5:18 am
No new posts Garbage on output file Hervey Martinez SYNCSORT 4 Wed Sep 27, 2017 12:50 am
No new posts File Aid tool to compare numeric data balaji81_k Compuware & Other Tools 2 Tue Sep 26, 2017 3:35 am
No new posts Compare yesterday's date to the one o... migusd SYNCSORT 11 Fri Sep 22, 2017 11:35 pm

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