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

Why we declare High & Low values in COBOL?


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

New User


Joined: 02 Sep 2010
Posts: 1
Location: Hyderabad

PostPosted: Mon Sep 06, 2010 3:50 pm
Reply with quote

Why we declare High & Low values in COBOL?
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Mon Sep 06, 2010 4:45 pm
Reply with quote

what do you mean?
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Mon Sep 06, 2010 5:03 pm
Reply with quote

Did you mean "what" instead of "why" in your question?

However if it's "why", I'd, probably say, there are occasions when you may wish to set a variable to an infinitely high or infinitely low number. For example, this thread might give you a hint.
Back to top
View user's profile Send private message
Binop B

Active User


Joined: 18 Jun 2009
Posts: 407
Location: Nashville, TN

PostPosted: Mon Sep 06, 2010 5:30 pm
Reply with quote

Quote:
Why we declare High & Low values in COBOL?
How can we "declare" High and Low values ? icon_rolleyes.gif
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Mon Sep 06, 2010 7:09 pm
Reply with quote

The "why" is real simple -- we need HIGH-VALUES or LOW-VALUES in the program.
Back to top
View user's profile Send private message
Kjeld

Active User


Joined: 15 Dec 2009
Posts: 365
Location: Denmark

PostPosted: Mon Sep 06, 2010 8:46 pm
Reply with quote

HIGH VALUE or LOW VALUE are typically used for initialising storage ares to prove that previous contents have been erased. In applications were your execution logic does not control the usual 'modify before reference' sequence it can be useful to use these special literal values to ensure your data areas are in a initialized state.
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 Replace each space in cobol string wi... COBOL Programming 3
No new posts INCLUDE OMIT COND for Multiple values... DFSORT/ICETOOL 5
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
No new posts COBOL ZOS Web Enablement Toolkit HTTP... COBOL Programming 0
No new posts Replace Multiple Field values to Othe... DFSORT/ICETOOL 12
Search our Forums:

Back to Top