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

What happens with the below PERFORM VARYING code


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

New User


Joined: 20 Feb 2006
Posts: 14

PostPosted: Thu Aug 23, 2007 6:57 am
Reply with quote

Hi,

can anyboday knows what exactly is happening or the given below peice of code is working...

PERFORM VARYING SUB FROM INDEX-CODE BY -1
UNTIL SUB NOT > THRESHOLD-LIMT


Thanks
Herewego.....
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Thu Aug 23, 2007 8:09 am
Reply with quote

Hello,

There is more code that you have not posted.

From the little you've posted, assume the PERFORM started with INDEX-CODE being greater than TRESHOLD-LIMIT. The code will iterate until SUB is no longer greater than THRESHOLD-LIMIT.

If you post more code and the associated variables, someone can provide more info for you.
Back to top
View user's profile Send private message
Balraj

New User


Joined: 16 Aug 2007
Posts: 34
Location: Bangalore

PostPosted: Thu Aug 23, 2007 10:03 am
Reply with quote

hi

Its a Inline Perform

The loop will executes and when it satisfy the condition control comes out

of the loop.
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 Replacing 'YYMMDD' with date, varying... SYNCSORT 3
No new posts run rexx code with jcl CLIST & REXX 15
No new posts Compile rexx code with jcl CLIST & REXX 6
No new posts REXX code to expand copybook in a cob... CLIST & REXX 2
No new posts Use of Perform Thru Exit COBOL Programming 6
Search our Forums:

Back to Top