IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

INSPECT verb to check whether it contains '*' or ';'


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
sdharitas

New User


Joined: 10 Mar 2005
Posts: 3
Location: Chennai

PostPosted: Thu Jan 12, 2006 2:59 pm
Reply with quote

Hi all,
i got a request. in that i need to check whether it contains '*' or ';'. if so, replace them with spaces. i used INSPECT.

INSPECT VAR replacing all '*' by ' '
INSPECT VAR replacing all ';' by ' '

can any body tell me is it correct or wrong.
Back to top
View user's profile Send private message
priyesh.agrawal

Senior Member


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

PostPosted: Thu Jan 12, 2006 3:40 pm
Reply with quote

Quote:
can any body tell me is it correct or wrong.

That is correct and will give you desired results.

Regards,

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

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Fri Jan 13, 2006 6:47 am
Reply with quote

It's probably more efficient to do it this way:

INSPECT VAR replacing all '*' by ' ' all ';' by ' '
Back to top
View user's profile Send private message
sdharitas

New User


Joined: 10 Mar 2005
Posts: 3
Location: Chennai

PostPosted: Tue Jan 17, 2006 3:07 pm
Reply with quote

Hi friends,
thanks for ur suggestions. i implemented and thats working fine.

Regards
Satya
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts SCOPE PENDING option -check data DB2 2
No new posts Check data with Exception Table DB2 0
No new posts How to check whether who renamed the ... JCL & VSAM 3
No new posts No ++JCLIN, APPLY CHECK job JCL & VSAM 1
No new posts EMPTY file check scenario JCL & VSAM 6
Search our Forums:

Back to Top