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
 

 

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: 8
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 TSO or command line utility to genera... kishpra JCL & VSAM 3 Thu Mar 09, 2017 1:11 am
No new posts find particular member name in PDS us... ravi243 CLIST & REXX 10 Mon Dec 19, 2016 6:44 pm
No new posts How to find the first monday of the w... abdulrafi COBOL Programming 10 Fri Nov 25, 2016 3:24 pm
No new posts Find out a active PGM jpsager JCL & VSAM 10 Fri Oct 07, 2016 4:32 pm
No new posts How to find a CICS resource used in C... Arunkumar Chandrasekaran CICS 8 Thu Sep 29, 2016 1:45 pm


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