Skip to content

Update Global Administration

Add special library types, and add a language and procedure for SQL stored procedures, to global administration for the base ChangeMan ZMF product.

Add Global Library Types for Db2

You assign Db2 Option functions to a library type with the Selectable Option field in the application library type definition and with the Sub-type field in Db2 Option library type definition.

This table shows you the kinds of components managed by the Db2 Option and the library type parameters that are required for each. Parameters that appear on library type definition panels are shown in bold.

Db2 Component Like Target Type Sel Opt Sub Typ BIND/SQL/SERVICE
Db2 Application Program Source **S **Db2 Program Load
Db2 Application Program Load **L B
DBRM **P **D R B
BIND PLAN Command **P **D B B
BIND PACKAGE Command **P **D P B
External Stored Procedure Source **S **Stored Procedure Load
External SQL Stored Procedure Source **S **Stored Procedure Load **D Q S
External Stored Procedure Load **L **D S B & S
Native SQL Stored Procedure **P **D N S
General DDL (e.g. CREATE PROCEDURE for external SP) **P **D D S
User Defined Function Definition **P **D D S
Trigger Definition **P **D T S
BIND Service command P D V V
Service GRANT command P D V V

* Db2 Active Library specification for BIND plan/pkg (B), Process SQL (S), and Bind Service (V).

Follow these steps to create global library type definitions for components managed by the Db2 Option:

  1. From anywhere in the ChangeMan ZMF ISPF client, type =A.G.2 on the Command or Option line and press Enter. The Global Library Types Part 1 of 2 panel CMNCGLT0 is displayed.

  2. Follow the instructions in the ChangeMan ZMF Administrator Guide to insert a library type row and create a new library type for each kind of Db2 component you will manage.

    CMNCGLT0          Global Library Types Part 1 of 2        Row 5 to 41 of 41
    Command ===> _____________________________________________ Scroll ===> CSR 
    
      Lib                                        Order Lke Seq Defer Target Sel
      type Description                         +                     type   Opt
      DBB  Db2 BIND PLAN Commands                0      P  001   Y          D
      DBR  Db2 DBRM                              0      P  001   Y          D
      DOC  Documentation                         0      P        Y
      ...
      OBJ  Object module library                 0      O        Y
      PKG  Db2 Bind Package Command              0      P        Y          D
      PRC  Cataloged Procedures                  0      P        Y          D
      SDB  Db2 Program Source                    0      S  003   Y   LDB    D
      SPD  Db2 Stored Proc Definitions - Non-SQL 0      P        Y          D
      SPN  Db2 Stored Proc Source - Native SQL   0      P        Y          D
      SPQ  Db2 Stored Proc Source - SQL Language 0      P        Y   STL    D
      SRC  Source for Programs to be Linked Exec 0      S        Y   LOD     
      SRS  Source for subprograms to be Linked N 0      S        Y   LOS    
      STL  Db2 Stord Prod Load Modules           0      L        Y          D
      STP  Db2 Stored Proc Source - External Lan 0      S        Y   STL    D
      TRG  Db2 Trigger Definitions               0      P        Y          D
      TST  Test Library type                     0      P        Y
      UDF  Db2 User-Defined Function Definitions 0      P        Y          D
      ...
      ZSS  Shared Baseline Subprogram Source     0      S        Y   ZLS
    

    Important

    On library types for stored procedure load modules, set the Data Set Type field to LIBRARY (PDSE) on the Global Library Types Part 2 of 2 panel. If stored procedure load libraries are defined as PDS, a link edit for stage, recompile, or relink of the stored procedure may fail with message IEW2606S.

    Type S on the Line Command for each new library type row to display the Global Library Types Part 2 of 2 panel. Note that to fully support native SQL SPs generated by Data Studio, you need to use VB and LRECL 255 records.

  3. Exit the Global Library Types panels and save your changes.

Add Global Language and Procedure for External SQL SPs

This is an optional step, only required if you need to continue to support External SQL SPs. External SQL stored procedures are processed through the Db2 precompiler to translate the source into the C language, which is then processed like an external stored procedure. Add a language for SQL stored procedures and add stage procedure CMNSQL.

Note

Do not confuse the CMNSQL procedure with the CMNCEE procedure that you use for external stored procedures written in C. The CMNSQL procedure imbeds skeleton CMN$$SQP to translate SQL code to C source before compiling and link editing the C source.

  1. From anywhere in the ChangeMan ZMF ISPF client, type =A.G.3 on the Command or Option line and press Enter. The Global Language Names panel CMNGGLNG is displayed.

  2. Insert a row and type a Language for SQL stored procedures. Language SQL is used in this example.

    CMNGGLNG                 Global Language Names              Row 1 to 9 of 9
    Command ===> _____________________________________________ Scroll ===> CSR
    
         Language Order
         ASM      0
         C        0
         COBOL    0
         COBOLE   0
         COBOL2   0
         JAVA     0
         PLI      0
         PLIE     0
         SQL      0
    **************************** Bottom of data *******************************      
    
  3. Exit the Global Language Names panel and save your changes.

  4. From anywhere in the ChangeMan ZMF ISPF client, type =A.G.4 in the Command or Option line and press Enter. The Compile Procedure List panel is displayed.

  5. Insert a row and type * in the Language field to display the Language Selection List panel. Select the new language for SQL stored procedures from the Language Selection List panel.

    CMNPRCNN              Compile Procedure List              Row 1 to 21 of 21
    Command ===> _____________________________________________ Scroll ===> CSR 
    
     Language  Procedure  Description                                   Order
     ASM       CMNASM     Stage assembler source                        0
     ASM       CMNASMOB   Stage assembler source to object              0
     ASM       CMNASM2L   Stage assembler source w/ 2 link edit         0
     ...
     PLI       CMNPLI     Stage PL/I source                             0
     PLI       CMNPLIOB   Stage PL/I source to object                   0
     PLIE      CMNPLIE    Stage Enterprise PL/I source                  0
     SQL       CMNSQL     Translate, compile, and link SQL Stored Proc  0
    **************************** Bottom of data *******************************
    
  6. Type CMNSQL in the Procedure field and type a description in the Description field.

  7. Exit the Compile Procedure List panel and save your changes.