MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Unstring - Help

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming
View previous topic :: View next topic  
Author Message
Vinodch
Beginner


Joined: 23 Dec 2002
Posts: 80
Topics: 32
Location: Chennai, India

PostPosted: Tue Mar 30, 2010 1:14 pm    Post subject: Unstring - Help Reply with quote

REC-1 = A|B|C|D|E|F|G|H|

UNSTRING REC-1 DELIMITED BY '|' INTO
A1
B1
C1
D1

I would like to have the o/p like mentioned below:

A1 = A
B1 = B
C1 = C
D1 = D|E|F|G|H|

but it is like below mentioned:

A1 = A
B1 = B
C1 = C
D1 = D

Please help is anyway D1 could store D|E|F|G|H|.
_________________
Thanks,
Vinod.
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12376
Topics: 75
Location: San Jose

PostPosted: Tue Mar 30, 2010 2:22 pm    Post subject: Reply with quote

Vinodch,

Unless i am missing something isn't it simple like this?

Code:

01 PTR           PIC S9(04) COMP.       

                 

MOVE +1           TO PTR                               
UNSTRING REC-1 DELIMITED BY '|' INTO A1 B1 C1
 POINTER PTR                                 
MOVE REC-1(PTR: ) TO D1                       


Kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Vinodch
Beginner


Joined: 23 Dec 2002
Posts: 80
Topics: 32
Location: Chennai, India

PostPosted: Tue Mar 30, 2010 3:30 pm    Post subject: Reply with quote

Kolusu

Yes - you are correct. I looked at one of your earlier replies and solved the issue.

Thanks for your help.
_________________
Thanks,
Vinod.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group