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

Length of DB2 VARCHAR in COBOL declaration


IBM Mainframe Forums -> Mainframe Interview Questions
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
raman.k

New User


Joined: 26 Feb 2007
Posts: 24
Location: chennai

PostPosted: Wed May 02, 2007 8:06 pm
Reply with quote

Hi
I want know the COBOL Db2 programme
In db2 one VARCHAR varibale is there. Now I declared the COBOL equailent. Like
EMP VARCHAR(20).
in COBOL
01 EMP.
49 Len s9(6) comp.
49 name x(20).

Why we need to use length. Can we change any other level number instead of 49.
Please tell describe me

Thanks
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Wed May 02, 2007 9:22 pm
Reply with quote

raman.k wrote:

01 EMP.
49 Len s9(6) comp.
49 name x(20).
Why we need to use length. Can we change any other level number instead of 49.
After a quick stop off at the FM, I found that it has to be 49. Why we need the length? What do you thing the definition of "variable" is?
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 -> Mainframe Interview Questions

 


Similar Topics
Topic Forum Replies
No new posts Store the data for fixed length COBOL Programming 1
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts PARSE Syntax for not fix length word ... JCL & VSAM 7
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
Search our Forums:

Back to Top