Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Need to find a word in a line

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
Raje1002

New User


Joined: 21 Feb 2009
Posts: 11
Location: India

PostPosted: Thu Jan 27, 2011 11:44 am    Post subject: Need to find a word in a line
Reply with quote

Hi all,

I want to see whether the word "COPY" is present in a line or not.

Currently I have a line which will tells if the "COPY" is present in the 3rd word of that line.

"IF WORD(CBLLINE,3) ¬= 'COPY' THEN ITERATE"

I want to perform a task if the word "COPY" is present in that line.

How to achecive this?
Back to top
View user's profile Send private message

Guest







PostPosted: Thu Jan 27, 2011 11:59 am    Post subject:
Reply with quote

Hi Raje1002,
The following can be used to find the presence of copy:

Code:


if Pos('copy',cblline) = 0 then
say 'no copy found'



devil13
There is always a better solution.
Back to top
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Thu Jan 27, 2011 2:14 pm    Post subject:
Reply with quote

I would go for WORDPOS...

O.
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Find a string in PS file opened in br... mukkas CLIST & REXX 2 Sat Feb 24, 2018 2:15 pm
No new posts Copying only first and last word from... chandan.inst SYNCSORT 4 Wed Jan 31, 2018 4:19 pm
No new posts line 52: Name or string > 250 char... Ashishpanpaliya CLIST & REXX 5 Sat Oct 14, 2017 2:29 am
No new posts How to write Rexx program to size and... sreejeshcs CLIST & REXX 14 Thu Oct 12, 2017 7:26 am
No new posts Command to find TMEMBER name for a TPIPE Siva NKK Kothamasu IMS DB/DC 0 Wed Aug 16, 2017 6:08 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us