Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How to unstring the following using double quotes

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
elonics

New User


Joined: 05 Jul 2005
Posts: 49
Location: India

PostPosted: Wed Aug 17, 2005 2:51 pm    Post subject: How to unstring the following using double quotes
Reply with quote

how to unstring the following using double quotes

"NTFILE001" "\O DRIVE\ACCEPT\SWF" 123456.00
Back to top
View user's profile Send private message

priyesh.agrawal

Senior Member


Joined: 28 Mar 2005
Posts: 1452
Location: Chicago, IL

PostPosted: Wed Aug 17, 2005 3:13 pm    Post subject: Re: unstring
Reply with quote

Why to post the same query again ...when you already did in another FORUM.

Quote:
"NTFILE001" "\O DRIVE\ACCEPT\SWF" 123456.00


Is this your I/P string.

place ur desired o/p too....

Regards,

Priyesh.
Back to top
View user's profile Send private message
elonics

New User


Joined: 05 Jul 2005
Posts: 49
Location: India

PostPosted: Thu Aug 18, 2005 9:05 am    Post subject: Re: How to unstring the following using double quotes
Reply with quote

my output should be

ntfile0001
\O DRIVE\ACCEPT\SWF
123456.00

please copy the exact string which i mailed previously.
there are space in between the double quotes.
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Fri Aug 19, 2005 7:17 am    Post subject:
Reply with quote

Code:

unstring yr-string delimited by '" "' or '"'
      into  dummy-str
             str1
             str2
             str3


The order of the delims in the stmt is important.
Back to top
View user's profile Send private message
harinatha

New User


Joined: 24 Jul 2005
Posts: 28

PostPosted: Sun Aug 21, 2005 10:53 pm    Post subject: Re: How to unstring the following using double quotes
Reply with quote

Hi Jack,

If the input string will contain zero or one or more spaces between double quotes, then how to delimit that string.

Thanks & Regards,
Hari.
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Mon Aug 22, 2005 2:57 am    Post subject:
Reply with quote

Hi Hari,

I'm not sure I understand your ques. My example shows a delim w/a space between the quotes.

Or are you saying that the spaces and or zeros are data you want to unstring into your receiving fields?

Why don't you provide an example of your I/P and the O/P fields after the unstring.
Back to top
View user's profile Send private message
elonics

New User


Joined: 05 Jul 2005
Posts: 49
Location: India

PostPosted: Mon Aug 22, 2005 10:20 am    Post subject:
Reply with quote

Hi All,
I resolved this.Thanx for all Who suggested me.My input string is
"NTFILE001" "\O DRIVE\ACCEPT\SWF" 123456.00 -- WS-INPUT-RECORD

UNSTRING WS-INPUT-REC DELIMITED BY ' " ' INTO WS-DUMMY1
WS-NAME
WS-DUMMY2
WS-DIR
WS-NO

BY DOING THIS I WILL HAVE
DOUBLE QUOTE IN WS-DUMMY1
NTFILE001 IN WS-NAME
SPACE AND DOUBLEQUOTE IN WS-DUMMY2
\O DRIVE\ACCEPT\SWF IN WS-DIR
REMAINING IN WS-NO.




Elo'nics.
--------------------------------------------------------------------------------
I may be the Best or Atleast better than many but i m never worst.
--------------------------------------------------------------------------------
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Translating Quotes Khadhar Basha CLIST & REXX 6 Tue May 09, 2017 11:52 am
No new posts Strings with double quotes having pro... raja Arumugam All Other Mainframe Topics 11 Thu Mar 30, 2017 10:34 am
No new posts Unstring list of values into an array. Roshnii COBOL Programming 8 Mon Jun 27, 2016 6:25 pm
No new posts To change double quotes into csv read... Robert Sample COBOL Programming 3 Fri Feb 19, 2016 8:13 am
This topic is locked: you cannot edit posts or make replies. Put quotes in Symbolic parameter whil... Yashashri All Other Mainframe Topics 7 Mon Feb 15, 2016 12:24 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us