View previous topic :: View next topic
|
Author |
Message |
GauravKudesiya Warnings : 1 New User
Joined: 11 Oct 2008 Posts: 74 Location: Chicago, IL
|
|
|
|
Hello All,
I am facing some complexity in unstring the following example.
I/P:
ECDC.BASE.COPYLIB UID(CH11001755) READ(A) WRITE(A) ALLOC(A)
Or
UID(CH11001755) ALLOW
I need to change the "CH11001755" with some new ID.
The format is like
Tk1_UID(<Some id>)_<Access>
Tk1 is not necessary, it may come and depends on runtime.
I need to take
TK1 UID(
<uid>
) <access>
in 3 tokens.
The problem i am facing is that i can use DELIMITED BY "("
so that everu thing before ( can be in token 1,
now i want to use next DELIMITOR at ")"
and then next DELIMITED BY SIZE.
but how to ppreform that....????
Thanks in Advance
Gaurav |
|
Back to top |
|
|
GauravKudesiya Warnings : 1 New User
Joined: 11 Oct 2008 Posts: 74 Location: Chicago, IL
|
|
|
|
Its done now.......... |
|
Back to top |
|
|
Terry Heinze
JCL Moderator
Joined: 14 Jul 2008 Posts: 1249 Location: Richfield, MN, USA
|
|
|
|
Please share your solution for the benefit of others. |
|
Back to top |
|
|
GauravKudesiya Warnings : 1 New User
Joined: 11 Oct 2008 Posts: 74 Location: Chicago, IL
|
|
|
|
sure...
i used
WS-D1 PIC X(1) VALUE '('
WS-D2 PIC X(1) VALUE ')'
.
.
.
UNSTRING OLD-REC DELIMITED BY "(" OR ")" INTO
OLD-1 DELIMITER IN WS-D1,
OLD-2 DELIMITER IN WS-D2,
OLD-3 DELIMITER IN SIZE.
EXPLAINATION:
OLD-REC = ECDC.BASE.COPYLIB UID(CH11001755) READ(A) WRITE(A) ALLOC(A)
OLD-1 = ECDC.BASE.COPYLIB UID
OLD-2 = CH11001755
OLD-3 = READ(A) WRITE(A) ALLOC(A)
SO ITS SOLVED.... |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Good to hear it is working - thanks for letting us know and posting your solution
d |
|
Back to top |
|
|
|