Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
USE OF DCLGEN

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
View previous topic :: :: View next topic  
Author Message
ragin

New User


Joined: 20 Feb 2005
Posts: 16

PostPosted: Thu Mar 10, 2005 9:54 am    Post subject: USE OF DCLGEN
Reply with quote

HELO FRNDZ,
CAN U PLZ TELL ME WHT IS THE EXACT USE OF DCLGEN IN DB2 AFTER CREATING A TABLE?
SO ENTERING INTO 8.2 OPTION(DCLGEN) IT ASKS FOR THE TABLE NAME,SUFFIX,PREFIX ECT........WHAT SOULD I GIVE THERE?
Back to top
View user's profile Send private message

ovreddy

Active User


Joined: 06 Dec 2004
Posts: 211
Location: Keane Inc., Minneapolis USA.

PostPosted: Thu Mar 10, 2005 11:14 am    Post subject:
Reply with quote

Hi Ragin,

DCLGEN is a subcomponent of DB2. It is used to generate Host variable declarations for a table. If we want to use a DB2 table in COBOL program we must declare Host variables which holds the data retrieved from DB2 table. This declarations can be automatically generated by using DCLGEN.

In DCLGEN we need to give the following options... Most of the options are optional...

Enter table name for which declarations are required:
1 SOURCE TABLE NAME ===> (Table name Table name for which we need host variables)
2 TABLE OWNER ..... ===> (Optional)
3 AT LOCATION ..... ===> (Optional)

Enter destination data set: (Can be sequential or partitioned)
4 DATA SET NAME ... ===> (Dataset name where we want to store this declarations)
5 DATA SET PASSWORD ===> (If password protected)

Enter options as desired:
6 ACTION .......... ===> ADD (ADD - adds to existing declarations if already exists, or REPLACE old declarations if exists)
7 COLUMN LABEL .... ===> NO (Enter YES for column label)
8 STRUCTURE NAME .. ===> (Optional)
9 FIELD NAME PREFIX ===> (HV-) (Optional)
10 DELIMIT DBCS .... ===> YES (Enter YES to delimit DBCS identifiers)
11 COLUMN SUFFIX ... ===> NO (Enter YES to append column name)
12 INDICATOR VARS .. ===> NO (Enter YES for indicator variables)

We can include the generated COPYBOOK into our cobol program as follows in working storage section...
EXEC SQL INCLUDE
EMPDCL
END-EXEC.

Bye,
Reddy.
Back to top
View user's profile Send private message
shan1245

New User


Joined: 03 Jun 2005
Posts: 1
Location: bangalore

PostPosted: Tue Jun 07, 2005 3:39 pm    Post subject: Need Xpeditor commands
Reply with quote

Hi All,

Can anyone send Xpeditor commands and document. I need it urgent.
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 -> DB2 All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Unable to view Unloaded file using DC... Rohit Umarjikar DB2 4 Thu Dec 31, 2015 6:46 pm
No new posts Expand COBOL copybooks and DCLGEN Mike 1304 COBOL Programming 17 Sun May 26, 2013 10:54 pm
No new posts DCLGEN change prino DB2 1 Tue Dec 25, 2012 1:13 am
No new posts USING DCLGEN as INPUT LAYOUT but will... grem Mainframe Interview Questions 2 Thu Jul 21, 2011 1:09 pm
No new posts Generating Multiple DCLGEN's enrico-sorichetti DB2 4 Mon Apr 04, 2011 8:39 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us