IBM Support

Bind Error SQLCODE = -798, on DB2 for z/OS

Technote (FAQ)


The Grouper metadata tables on DB2® for z/OS® were updated in PTF UQ87853. The DBRMs that shipped in the PTF UQ87853 requires the updates that were made to the metadata tables. After the PTF has been installed, the metadata tables must be migrated so that the DBRMs and the metadata become compatible.


The cause of this problem is a mismatch between the DBRMs and the metadata tables against which they were bound.


You can verify the version of the Grouper metadata tables by issuing the query:


If the version displayed is '101', you must complete the steps below to migrate to the new release level.

NOTE: If you have either not run a Grouper function such as Group Discovery or Spinner that has placed data in the Grouper metadata tables, or if you do not want the data to be preserved during the migration/upgrading process, skip Steps 1 through 5. Instead, run EGFDDLD, EGFDDLC, and EGFFISH from SPUFI to create the latest version of Grouper metadata tables.
Only run EGFDDLD if the Grouper tables and views have been previously created. The value of 'VERSION' in the table 'SYSTOOLS.EGF_PROPERTIES' will be 102 after EGFDDLC has been run.

For upgrading Grouper to the new release level on DB2 V7 and DB2 V8 in Compatibility mode:

1. Modify the parameters in the JCL 'EGFMIGI' and run it. This
procedure creates a copy of EGFDDLC with the 'START WITH'
value of IDENTITY columns updated to maximum value of the
IDENTITY column in the corresponding table, plus one
(max(ID) + 1). You can then customize the newly generated
'DDLC' as needed.

2. Unload the data in the existing Grouper metadata tables
using the sample JCL 'EGFUNLD', in the data set SEGFSAMP.
Follow the instructions in the JCL before you run it.
EGFUNLD creates SYSREC and SYSPUNCH data sets for each of
Follow the instructions in the JCL before you run it.
EGFUNLD creates SYSREC and SYSPUNCH data sets for each of
the tables unloaded. The SYNPUNCH data sets contain the
generated load statement for the corresponding table.
Make sure the size specified for the SYSREC data sets,
in EGFUNLD, is large enough.

3. Drop the existing Grouper metadata tables using the
member EGFDDLD (from SPUFI).

4. Recreate the Grouper metadata tables using the new 'DDLC'
and the views (interface for tools to access Grouper
data) using the member EGFFISH (from SPUFI).

5. Load the data into the newly created tables using the
member 'EGFLOAD'. The load statement in the SYSPUNCH
data sets needs to be edited. Follow the instructions
provided in the JCL 'EGFLOAD', before you run the

After Step 5 is completed, the following query should print the new release level (102):


6. Install the new stored procedure JAR file (egfsproc.jar)
in the USS directory.

7. Update the environment variable CLASSPATH in the JAVAENV
data set to refer to the latest egfsproc.jar. The WLM
must be in the quiesced mode while you are editing the
data set.

8. Issue the 'Create procedure' statements using
the member EGFCPRC (if they do not already
exist). Make sure the WLM environment name in the
'CREATE PROCEDURE' statements is correct.

9. Run the JCL EGFJBND and then EGFGBND. EGFJBND binds the
JDBC DBRMs to the collection DSNJDBC, and EGFGBND
binds the Grouper stored procedure DBRMs (EGF11
through EGF14) to the collection DSNJDBC.

If you ran the db2genJDBC utility, the JDBC DBRMs will be in the data set that the
property 'DB2SQLJDBRMLIB' was set to. For more information, refer to the Application Programming Guide and Reference for JAVA.The CLASSPATH in the WLM JAVAENV data set should point to the USS directory containing the corresponding JDBC customized profile 'DSNJDBC_JDBCProfile.ser'.
    If you use the JDBC customized profile that DB2 provides (you can find it in '/usr/lpp/db2810/classes', and if SQLJ and JDBC are installed in /usr/lpp/db2810), then the JDBC DBRMs (DSNJDBC1...DSNJDBC4) that are in the DSNXXX.SDSNDBRM data set must be bound.

    10 . Refresh the WLM using the command:
      v wlm,applenv=<name of the WLM>,refresh

    11. Issue the following SQL statement:
        insert into SYSTOOLS.EGF_PROPERTIES values ('EGFLOGDIR', '<log-directory>');
    <log-directory> must be changed to a USS directory into which the server log files are written at runtime. The log-directory can be any USS directory.
    If you are running the Grouper stored procedure, you must have write
    permission in this directory.

    12. Rebind the Spinner packages and plan.

    Document information

    More support for: DB2 Tools for z/OS
    DB2 Grouper Component

    Software version: 1.1.0

    Operating system(s): z/OS

    Reference #: 1202602

    Modified date: 20 January 2006

    Translate this page: