IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

can any one help meto draw this code ?


IBM Mainframe Forums -> PL/I & Assembler
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
rskumar

New User


Joined: 21 Nov 2005
Posts: 35
Location: chennai

PostPosted: Thu Aug 31, 2006 12:29 pm
Reply with quote

1) Must read input data from a file. The records will be in the below structure format



01 Input file,

02 Field name1,

02 Field Value.

02 Field name2,

02 Field Value.

02 Field name3,

02 Field Value.

02 Field name4,

02 Field Value.





2) Mask the contents of the Field Value(1-4) as below

a. All Upper Case Letters must be replaced with Upper Case Alphabets starting from A

Eg: RAMMAOO------- ABCDEFGHI

b. All Lower Case Letters must be replaced with Lower Case Alphabets starting from a

Eg: rammaakd ------- abcdefghi

c. All Numeric values must be replaced with numbers starting from 0

Eg: 23451234 ------- 01234567



d) Special characters must be retained as given in input



3) Write the masked data to the output file



Example Conversions



1) ramaaaa*udjduhdduh*shdhndhx*234121 Should be masked to Abcdefghi*Jklmnopqrs*Tuvwxyzab*123456
Back to top
View user's profile Send private message
Murali krishna

New User


Joined: 17 Feb 2006
Posts: 9
Location: chennai

PostPosted: Tue Sep 19, 2006 5:06 pm
Reply with quote

Hi Kumar,
First you need toc chk is it possible to have a combination of lower and upper letter for field names.If not you can adopt the following procedure.

Declare a structure of above format.
read the input file into the Structure.For all the field names you can find the starting letter using SUBSTR option.if it is lower then find the length of the string and replace with lower case letters.

ex:- let us take the masking for 'ramaaaa'
SUBSTR(FIELDNAME1,1,1) will be 'r' then
Length(Fieldname1) will be '7' so you write 'abcdefg'

like this you can do for reaminig field names as well as 'field values'
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> PL/I & Assembler

 


Similar Topics
Topic Forum Replies
No new posts run rexx code with jcl CLIST & REXX 15
No new posts Compile rexx code with jcl CLIST & REXX 6
No new posts REXX code to expand copybook in a cob... CLIST & REXX 2
No new posts VSAM return code 23 - for a Random read COBOL Programming 4
No new posts Monitoring production job progress. N... JCL & VSAM 4
Search our Forums:

Back to Top