IBM MAINFRAME HELP & SUPPORT FORUMS
Technical Forums for IBM Mainframe Applications like COBOL, JCL, CICS, DB2, FileAid, DFSORT, Endevor, Xpediter, CoolGen, CA-7&11, AbendAid, IMS, IDMS, PL/I, MqSeries, SyncSort, Assembler, ChangeMan, Easytrieve, InterTest, REXX, CLIST etc...
 

How to change numeric to character after only a specific wrd

THIS IS AN ARCHIVE FORUM: CLICK HERE TO GO TO THE ORIGINAL TOPIC

 
       IBMMAINFRAMES.com - IBM Mainframe Support Forums Index -> Mainframe COBOL
View previous topic :: View next topic  
Author Message
ssprabhu



Joined: 25 Apr 2005
Posts: 54
Location: pune

Posted: Thu Aug 21, 2008 3:08 pm    Post subject: How to change numeric to character after only a specific wrd  

Hi,

customer opted for e-account account no: 123456 cust-id : 22222 and
opted on 13/08/08 at 12:13.

customer opted for e-account opted on 13/08/08 at 12:13, Account no: 123456 cust-id : 22222 and


I want to change this above stmt as's below..

customer opted for e-account account no: XXXXXX cust-id : XXXXXX and
opted on 13/08/08 at 12:13.

customer opted for e-account opted on 13/08/08 at 12:13, Acc no: XXXXXX cusid : XXXXXX

But this text is nott constant the account no and cust-id details can appear at any place in the sentence ..so what all i need todo is i have to sweep all the text in the database and to find is there any accout details or cust-id details in the text then i have to replace the next 6 bytes as "X"

Is there any cobol statement available for this or any least and efficient method can u please suggest ??
Back to top  
Aaru



Joined: 03 Jul 2007
Posts: 1148
Location: Mumbai - India

Posted: Thu Aug 21, 2008 3:19 pm    Post subject: Reply to: How to change numeric to character after only a sp  

ssprabhu,

Quote: or any least and efficient method can u please suggest ??

I would probably go for REXX as the customer ID value is not a constant and is not in a specific position.

If you know rexx, read the file, check for account no: and cust id: Acc no: cusid : and then overlay the data XXXXXX.
Back to top  
ssprabhu



Joined: 25 Apr 2005
Posts: 54
Location: pune

Posted: Thu Aug 21, 2008 4:00 pm    Post subject:  

AAru yes but...u know we need to sweep millions of customers and their text ..we hae to keep restart both internal and external tahtz not possible in REXX so we heve to do it in cobol...
Back to top  
ssprabhu



Joined: 25 Apr 2005
Posts: 54
Location: pune

Posted: Thu Aug 21, 2008 6:46 pm    Post subject:  

Experts view please...
Back to top  
Frank Yaeger



Joined: 15 Feb 2005
Posts: 4613
Location: San Jose, CA

Posted: Thu Aug 21, 2008 9:12 pm    Post subject:  

ssprabhu,

Since you posted in the DFSORT Forum, I assume a DFSORT solution would be desirable. Right?

If you want to do this in COBOL, why did you post in the DFSORT Forum?

You can use DFSORT's new FINDREP function to do this kind of thing. FINDREP is available with z/OS DFSORT V1R5 PTF UK90013 (July, 2008).
If you clarify what you want, I can show you how to do it:

It isn't clear which keywords you are looking for. Your input and output records have all of these variations:

'account no:'
'cust-id :'
'Account no:'
'Acc no:'
'cusid :'

Please give a complete, accurate list of the keywords you are actually looking for.

Also, the customer ids you show are 5 bytes, but you say you want to replace them with 6 bytes. Are the customer ids really 6 bytes?

A better example of input and output would help.
Back to top  
ssprabhu



Joined: 25 Apr 2005
Posts: 54
Location: pune

Posted: Tue Aug 26, 2008 1:27 pm    Post subject:  

Iam sorry Frank Yaeger for postinf tis thread in DF SORT forum..
Back to top  
enrico-sorichetti



Joined: 14 Mar 2007
Posts: 3168
Location: italy

Posted: Tue Aug 26, 2008 2:26 pm    Post subject: Reply to: How to change numeric to character after only a sp  

looks like You are trying to implement some form of data masking ( for sensitive info )

Your organization should define better the long term requirements,
if it is once in a while it might be ok to go for an in house solution,

for continuous use I feel that it would be wiser to go for a full solution product

if You google for "sensitive data masking sanitization" You will find lots of documents and pointers on different ways of doing it
( also some product pointers )
Back to top  
 
       IBMMAINFRAMES.com - IBM Mainframe Support Forums Index -> Mainframe COBOL
Page 1 of 1
THIS IS AN ARCIVE FORUM IN READ ONLY MODE. IF YOU WANT TO ASK YOUR DOUBTS USE THE ACTUAL FORUM