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
 

 

Use of WHEN condition with OR

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

New User


Joined: 26 Feb 2007
Posts: 71
Location: bangalore

PostPosted: Fri Mar 23, 2007 4:15 pm    Post subject: Use of WHEN condition with OR
Reply with quote

How WHEN condition is used with OR condition
Back to top
View user's profile Send private message

William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Fri Mar 23, 2007 4:38 pm    Post subject:
Reply with quote

As in EVALUATE? It isn't.
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1187
Location: Bangalore,India

PostPosted: Fri Mar 23, 2007 5:32 pm    Post subject:
Reply with quote

Hi Deepak,

There is no need to put OR condition in when clause

EX

Code:
EVALUATE POLICY-CLASS
   WHEN '81'
   WHEN '83'
             PERFORM PARAA
   WHEN 'E1'
   WHEN 'E3'
             PERFORM PARAB
   WHEN 'M2'
   WHEN 'M3'
             PERFORM PARAC
   WHEN OTHER
             PERFORM PARAD
END-EVALUATE 


In the above code if policy class is 81 or 83 it will execute PARAA
If it is E1 or E3 then it will execute PARAB if it is M2 or M3 then it will execute PARAC otherwise for rest of the classes it will execute PARAD

Hope it's answered ur question.
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
This topic is locked: you cannot edit posts or make replies. Need help on If condition continuatio... ashok_uddaraju CLIST & REXX 4 Fri May 19, 2017 8:55 am
No new posts Joinkeys with condition scdinesh DFSORT/ICETOOL 10 Tue Feb 14, 2017 12:20 am
This topic is locked: you cannot edit posts or make replies. How to pass the previous month date i... Suganya87 DFSORT/ICETOOL 5 Mon Oct 31, 2016 4:13 pm
No new posts INCLUDE condition questions van bui DFSORT/ICETOOL 1 Thu Jun 30, 2016 9:52 am
No new posts 2 vsam file compare and update a fiel... ABINAYATHULASI DFSORT/ICETOOL 6 Sun May 29, 2016 11:15 am


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