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

Evaluate with IFcondition


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

New User


Joined: 23 Mar 2005
Posts: 25

PostPosted: Wed Apr 20, 2005 2:58 pm
Reply with quote

can we use IF Statement with in Evaluate.

thank,s
keerthi.
Back to top
View user's profile Send private message
somasundaran_k

Active User


Joined: 03 Jun 2003
Posts: 134

PostPosted: Wed Apr 20, 2005 8:09 pm
Reply with quote

Keerthi,
You mean something like
Code:

EVALUATE TRUE
  WHEN X = Y
    IF A = B
      do some thing
    END-IF
  WHEN ---
 ----
---
END-EVALUATE.


Of course you can do it.

hth
-Som
Back to top
View user's profile Send private message
kanak

Moderator


Joined: 12 Mar 2005
Posts: 252
Location: India

PostPosted: Wed Apr 20, 2005 8:58 pm
Reply with quote

yes keerthi
you can do it any way..i.e one somasundaran_k has explained as well as inside if you can check for evaluate. both wau it is possible.
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Thu Apr 21, 2005 5:55 am
Reply with quote

I know this is really just a matter of taste, but I like to use the opposite; it seems to "read" better:
Code:

IF FLD-A = 6
    EVALUATE FLD-B
    WHEN 12 .....
         .....
    END-EVALUATE
END-IF
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 Evaluate variable to execute a jcl step JCL & VSAM 3
No new posts Evaluate statement, when-clause in co... COBOL Programming 10
No new posts Generate report with out using IF/EVA... COBOL Programming 25
This topic is locked: you cannot edit posts or make replies. Want to put in a loop in EVALUATE COBOL Programming 24
No new posts Evaluate statement - clarification COBOL Programming 2
Search our Forums:

Back to Top