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 option in Easytrieve

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


Joined: 12 Feb 2008
Posts: 142
Topics: 67

PostPosted: Wed Oct 21, 2009 1:36 pm    Post subject: Unstring option in Easytrieve Reply with quote

Hi,

Is there any function similar to Cobol Unstring, in Easytrieve?

I have a record

12345;Arvind;arv.vind@mail.com;develop

I want to unstring these and place the Name, Mail id in their respective fields.

Thanks
_________________
Arvind
"You can make a difference with your smile. Have that with you always"
Back to top
View user's profile Send private message Yahoo Messenger
kolusu
Site Admin
Site Admin


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

PostPosted: Thu Oct 22, 2009 10:04 am    Post subject: Reply with quote

arvibala,

AFAIK, easytrieve does NOT have any string manipulations functions. However you can write your own unstring logic using DO until/while . Here are some of the examples. check out the solutions posted by me

http://mvsforums.com/helpboards/viewtopic.php?t=1911&highlight=eztpa00
http://mvsforums.com/helpboards/viewtopic.php?t=8829&highlight=eztpa00
http://mvsforums.com/helpboards/viewtopic.php?t=4036&highlight=eztpa00

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


Joined: 12 Feb 2008
Posts: 142
Topics: 67

PostPosted: Thu Oct 22, 2009 10:48 am    Post subject: Reply with quote

Thanks Kolusu,

Did the same using Do Until and having counters to read the delimited ";" for name and email address.

I started the Index variable from 0 and it gave correct results. Your example starts index variable with 1. Do u see any prob with mine?

Im not posting the code as it is much similar to ur examples.

Thanks,
_________________
Arvind
"You can make a difference with your smile. Have that with you always"
Back to top
View user's profile Send private message Yahoo Messenger
kolusu
Site Admin
Site Admin


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

PostPosted: Thu Oct 22, 2009 5:04 pm    Post subject: Reply with quote

arvibala,

If you used index then start of value of 0 or 1 does not make a difference. but with a subscript it would be an error.

Kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
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