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
 

 

Condition 88 level

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

New User


Joined: 09 Sep 2008
Posts: 39
Location: india

PostPosted: Thu Feb 19, 2009 9:50 am    Post subject: Condition 88 level
Reply with quote

hi all,
I have lil confusion over this condition names use..please help me out to get rid of this confusion
i have a declaration

05 SUBV-FOUND-SW PIC X(01) VALUE 'N'.
88 SUBV-FOUND VALUE 'Y'.
88 SUBV-NOT-FOUND VALUE 'N'.

now somewhere i'm moving

MOVE 'Y' TO SUBV-FOUND-SW

now my question is, what value would be in

SUBV-FOUND and in SUBV-NOT-FOUND


Thanks,
Ajay
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Thu Feb 19, 2009 10:32 am    Post subject:
Reply with quote

Hello,

Quote:
now my question is, what value would be in
SUBV-FOUND and in SUBV-NOT-FOUND
There would be no values in them - they occupy no space (no pic(-)). They are conditions for values in the subv-found-sw.

If you look at the output of a compile, notice that they have no length and displacement.

When you move 'y' to the subv-found-sw, the statement
Code:
IF SUBV-FOUND
will test true. If the code was
Code:
IF SUBV-FOUND-SW = 'y'
this would process the same way.
Back to top
View user's profile Send private message
ajaybshukla

New User


Joined: 09 Sep 2008
Posts: 39
Location: india

PostPosted: Thu Feb 19, 2009 11:13 am    Post subject:
Reply with quote

Hi Dick,
05 SUBV-FOUND-SW PIC X(01) VALUE 'N'.
88 SUBV-FOUND VALUE 'Y'.
88 SUBV-NOT-FOUND VALUE 'N'.

MOVE 'Y' TO SUBV-FOUND-SW

if i check

IF SUBV-NOT-FOUND

will it false or true after moving 'Y' to SUBV-FOUND-SW

Thanks,
Ajay
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Thu Feb 19, 2009 11:15 am    Post subject:
Reply with quote

Hello,

If you move "Y" to subv-found-sw, IF SUBV-NOT-FOUND will be false.
Back to top
View user's profile Send private message
Terry Heinze

JCL Moderator


Joined: 14 Jul 2008
Posts: 1249
Location: Richfield, MN, USA

PostPosted: Thu Feb 19, 2009 9:58 pm    Post subject:
Reply with quote

The Language Reference Manual explains conditional variables in detail and has lots of examples. Search for "conditional variable".
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Thu Feb 19, 2009 10:24 pm    Post subject: Reply to: Condition 88 level
Reply with quote

If the field itself (SUBV-FOUND-SW) was equal to a value of other than 'Y', then the following IF would be TRUE at the 88 level -

Code:

IF  NOT SUBV-FOUND

If this were to be coded without using the 88 level, it would be -

Code:

IF  SUBV-FOUND-SW NOT = 'Y'

Regards,
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