Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search Memberlist Usergroups Profile Log in to check your private messages Log in
 
what is the use of comp, comp-1,comp-2

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe COBOL
Author Message
greek

New User


Joined: 28 Apr 2005
Posts: 3

PostPosted: Tue May 03, 2005 7:30 pm    Post subject: what is the use of comp, comp-1,comp-2
Reply with quote

hi all,
what is the use of comp, comp-1,comp-2.





thanks in advance
Back to top
View user's profile Send private message
References
kanak

Moderator


Joined: 12 Mar 2005
Posts: 259
Location: India

PostPosted: Tue May 03, 2005 7:44 pm    Post subject:
Reply with quote

hi please check the following link

http://www.ibmmainframes.com/viewtopic.php?t=2282&highlight=
hope this help you.If not please let us know, i think some of experts can reply more better way
Back to top
View user's profile Send private message
priya

Moderator


Joined: 24 Jul 2003
Posts: 624
Location: Bangalore

PostPosted: Wed May 04, 2005 7:51 am    Post subject:
Reply with quote

Try this also:

http://www.ibmmainframes.com/viewtopic.php?t=274

http://www.ibmmainframes.com/viewtopic.php?t=241
Back to top
View user's profile Send private message
dearhari2155

New User


Joined: 23 May 2005
Posts: 2

PostPosted: Mon May 23, 2005 5:38 pm    Post subject:
Reply with quote

For better Storage apce utilization
Back to top
View user's profile Send private message
subhasis_50

Moderator


Joined: 09 Mar 2005
Posts: 367
Location: Earth

PostPosted: Mon May 23, 2005 5:50 pm    Post subject: Re: what is the use of comp, comp-1,comp-2
Reply with quote

Hi,
If you want to know details about COMP variable see the following link
http://www.discinterchange.com/TechTalk_COBOL_comp_.html
Back to top
View user's profile Send private message
eashwar

New User


Joined: 21 May 2005
Posts: 26
Location: Bangalore

PostPosted: Tue May 24, 2005 2:37 am    Post subject: Re: what is the use of comp, comp-1,comp-2
Reply with quote

there are usage classes like this

display
comp-1
comp-2
comp-3 or packed-decimal
comp-4 or binary or comp
comp-5

comp is internal binary representation
comp-1 is one word floating poin representation with no pic clause
comp-2 is two word floating point repr with no pic clause
comp is used for loop variables, indexes and variables used in arithmetic calculations
for others refer links
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe COBOL All times are GMT + 6 Hours
Page 1 of 1