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
 

 

wht is differenece b/w 77 level and 01 ?

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

New User


Joined: 10 Mar 2006
Posts: 9

PostPosted: Mon Mar 20, 2006 10:17 am    Post subject: wht is differenece b/w 77 level and 01 ?
Reply with quote

hi

wht is differenece b/w 77 level and 01 ?......

Title changed from "vscobol ii" to "wht is differenece b/w 77 level and 01 ?" : Priyesh.
Back to top
View user's profile Send private message

priyesh.agrawal

Senior Member


Joined: 28 Mar 2005
Posts: 1452
Location: Chicago, IL

PostPosted: Mon Mar 20, 2006 10:31 am    Post subject: Re: vscobol ii
Reply with quote

77 level number is used for declaring elementary data items.
01 level number can be used for both elementary data items and sub-group.

Like...


Code:
77 WS-DATE   PIC X(10).

01 WS-DATE1.
   05 WS-DAY   PIC X(2).
   05 FILLER   PIC X(1) VALUE '-'.
   05 WS-MONTH   PIC X(2).
   05 FILLER   PIC X(1) VALUE '-'.
     05 WS-YEAR   PIC X(4).


Regards,
Priyesh.
Back to top
View user's profile Send private message
sanath_m

New User


Joined: 10 Mar 2006
Posts: 9

PostPosted: Mon Mar 20, 2006 10:59 am    Post subject: Re: wht is differenece b/w 77 level and 01 ?
Reply with quote

01 a pic 99.
77 b pic 99.

move 0 to a b.

how much memory occupied 77 level and 01 level.....Both are same.....
Back to top
View user's profile Send private message
priyesh.agrawal

Senior Member


Joined: 28 Mar 2005
Posts: 1452
Location: Chicago, IL

PostPosted: Mon Mar 20, 2006 11:49 am    Post subject: Re: wht is differenece b/w 77 level and 01 ?
Reply with quote

Quote:
how much memory occupied 77 level and 01 level.....Both are same.....

Yes in terms of memory occupied both would be same. But coding a 01 gives you advantage that you can further sub-group the variable.

In earlier versions of COBOL it was different for 01 & 77 in terms of storage but these are same for VS COBOL II.

Regards,
Priyesh.
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
No new posts Syncsort TPF Level Majid Hussain SYNCSORT 2 Wed Apr 13, 2016 2:22 am
No new posts Need a logic to validate the data in ... sandeep kumar302 COBOL Programming 17 Mon Feb 01, 2016 3:30 pm
No new posts DB2 10.1 Share level locking and Sele... Mary Lewis DB2 1 Wed Apr 15, 2015 9:51 pm
No new posts CICS SE Level Openings in Accenture enikhilk Mainframe Jobs 0 Mon Sep 01, 2014 6:39 pm
No new posts 88 level variable logic not working sandeep kumar302 COBOL Programming 19 Thu Jul 31, 2014 10:59 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us