LOB Objects commented out when generated using RC/Query HDDL
search cancel

LOB Objects commented out when generated using RC/Query HDDL

book

Article ID: 76429

calendar_today

Updated On:

Products

RC/Query for DB2 for z/OS

Issue/Introduction

The RC/Query for Db2 for z/OS (RCQ) HDDL line command creates the data definition language(DDL) statements for the selected object along with
its parent and dependent objects. The HDDL (hierarchical DDL) command generates DDL online and in batch,  in the proper execution order, for those objects in its hierarchy.

When DDL is generated using the HDDL command the objects that are Auxiliary LOB tablespaces , Tables and Indexes are generated as '--' comments.

Resolution

A new feature provided in RCQ r20 release with the HDDL and DDL commands now generate DDL for implicitly created objects such as databases, tablespaces, tables,
and indexes as comments. This formatting enables the generated DDL to be executed without having to comment out the implicit object DDL manually.


For example when "SET CURRENT RULES = 'STD" (SQL standard rules)  is being used, Db2 is expected to generate the implicit objects for you when the DDL is executed.
Having these objects generated as comments could be of use as a way of preserving the DDL as it was or to be used in another SSID where the same SQL Standard Rules are not in place.

Note: There are other situations where implicit objects are created by Db2.

Sample Output:
 SET CURRENT SQLID = 'authid';
--
--     CREATE LOB TABLESPACE tsname
--            IN dbname
--            USING STOGROUP stogroup
--                PRIQTY -1
--                SECQTY -1
--                ERASE NO
--            BUFFERPOOL BP1
--            DSSIZE 4G
--            CLOSE YES
--            LOCKMAX SYSTEM
--            GBPCACHE CHANGED
--            DEFINE NO
--            LOGGED
--            LOCKSIZE ANY;


 SET CURRENT SQLID = 'authid';

--
--     CREATE AUXILIARY TABLE authid.lobtable
--         IN dbname.tsname
--         STORES authid.xx_xxxxx_xxxxxxx
--         APPEND NO
--         COLUMN xxxxx_xxxx PART 6;

Additional Information

Implicit Object DDL Now Generated as Comments

Generate Hierarchical Object DDL