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

How storage is calculated for AN-Edit variable?


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

Active User


Joined: 27 Sep 2008
Posts: 193
Location: chennai

PostPosted: Wed Mar 09, 2016 3:51 pm
Reply with quote

Hi all,

I have a variable defined in the following form.

77 VAR1 PIC ABAB(8).

And moving a value of 'PITFALL' to VAR1.

At display it shows only "P I".
But the storage allocated is 11 bytes.

How the length is calculated by compiler?

Your comments are expected.

Regards
Raghu
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Wed Mar 09, 2016 4:30 pm
Reply with quote

Your picture-string contains two characters, separated by a blank, and followed by eight blanks. That adds up to 11 bytes.
Back to top
View user's profile Send private message
Raghu navaikulam

Active User


Joined: 27 Sep 2008
Posts: 193
Location: chennai

PostPosted: Thu Mar 10, 2016 10:51 am
Reply with quote

Thanks for your quick replay.
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 Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts CLIST - Virtual storage allocation error CLIST & REXX 5
No new posts Query on edit primary command CLIST & REXX 5
No new posts Query on edit primary command CLIST & REXX 1
No new posts CICS vs LE: STORAGE option CICS 0
Search our Forums:

Back to Top