Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref

Author Message
ajayvamsi
Currently Banned

New User

Joined: 21 Jul 2005
Posts: 56

 Posted: Wed Dec 19, 2007 5:57 pm    Post subject: command in file-aid to Hi all, In a file I have junk/INVLAID data now using file - aid we can change this invalid data into zeroes for numeric's..wat ever required we can do this in file-aid using a command but could not remember can any one help me out in this. thanks ajay

krisprems

Active Member

Joined: 27 Nov 2006
Posts: 649
Location: India

 Posted: Wed Dec 19, 2007 6:34 pm    Post subject: what do you mean by junk/INVLAID data? show some sample i/p and o/p records?

Active User

Joined: 05 Dec 2006
Posts: 147
Location: Columbia, MO

Posted: Thu Dec 20, 2007 12:43 am    Post subject: Reply to: command in file-aid to

FileAid allows you to change data - but given data - that means that you must specify exactly what is to be replaced by a given value:

 Code: \$\$DD01  UPDATE IF=(91,EQ,C'A90')',REPL=(91,C'B01'),PRINT=0 /*

This statement updates the file in place. Specifically, if position 91 = A90, change it to B01.

You could try using something like IF=(91,GT,X'00'),etc.

Good luck.
ajayvamsi
Currently Banned

New User

Joined: 21 Jul 2005
Posts: 56

 Posted: Thu Dec 20, 2007 10:00 am    Post subject: hey it is not to execute thru JCL it can be change using LINE COMMAND I am not sure on that line command so I put the query...Please help me with the line command to change Invalid data in file-aid to zeroes... if u open the file thru file-aid and type the command it will change all the invalid data into zeroes...for that field... thanks ajay
krisprems

Active Member

Joined: 27 Nov 2006
Posts: 649
Location: India

Posted: Thu Dec 20, 2007 10:57 am    Post subject:

ajayvamsi
1. open the file in EDIT mode in your FILE-AID
2. Now give an ordinary TSO CHANGE command like this
 Code: C 1 0 ALL
in the above example all occurances of 1 would be replaced with 0's.
3. If you want to replace all 1's by o's at particular position in a file
 Code: C '1'  '0' 4 ALL
The above command will replace all occurances of 1 to 0's in the position 4.
Santoshdorge

New User

Joined: 27 Jun 2006
Posts: 48
Location: Pune

 Posted: Thu Dec 20, 2007 3:02 pm    Post subject: Hi Ajay, I am not sure wheather you want to change only invalid occurances in particular column or whole column contains invalid values. if the first is true then may be you need to do it in JCL or if there are only few INVALID VALUES then use F \invalid 1 ----where 1 is first column then change it manually to zero and in case you want to set whole column to zero....try this c any '0' 1 all thanks, Santosh
ajayvamsi
Currently Banned

New User

Joined: 21 Jul 2005
Posts: 56