DB2 Version 9.7 for Linux, UNIX, and Windows

GET_DB_CONFIG procedure

Note: This procedure has been deprecated and replaced by the DBCFG administrative view - Retrieve database configuration parameter information.
Read syntax diagramSkip visual syntax diagram
>>-GET_DB_CONFIG--(--)-----------------------------------------><

The schema is SYSPROC.

The GET_DB_CONFIG procedure returns database configuration information. The procedure does not take any arguments.

The procedure returns a single result set with two rows containing a column for each parameter. The first column is named DBCONFIG_TYPE, as shown in next table.

Table 1. Information returned by the GET_DB_CONFIG procedure
Column name Data type Description
DBCONFIG_TYPE INTEGER The row with a value of 0 in this column contains the values of the database configuration parameters stored on disk. The row with a value of 1 in this column contains the current values of the database configuration parameters stored in memory.

This procedure requires a user temporary table space that is used to create a global temporary table named DB_CONFIG to store the result set.

Authorization

One of the following authorities is required to execute the procedure:
  • EXECUTE privilege on the procedure
  • DATAACCESS authority
  • DBADM authority
  • SQLADM authority

Example

Using the command line processor (CLP), change the value of the logretain and the userexit database configuration parameters. Retrieve the original (on disk) and updated (in memory) values by calling the GET_DB_CONFIG procedure and then querying the resulting global temporary table (DB_CONFIG).
CONNECT TO SAMPLE

CREATE BUFFERPOOL MY8KPOOL SIZE 250 PAGESIZE 8K

CREATE USER TEMPORARY TABLESPACE MYTSP2 PAGESIZE 
   8K MANAGED BY SYSTEM USING ( 'TSC2' ) BUFFERPOOL MY8KPOOL

UPDATE DB CFG USING LOGRETAIN RECOVERY USEREXIT ON

CALL SYSPROC.GET_DB_CONFIG()

SELECT DBCONFIG_TYPE, LOGRETAIN, USEREXIT 
   FROM SESSION.DB_CONFIG

CONNECT RESET
The following example is a sample output from this query.
DBCONFIG_TYPE LOGRETAIN   USEREXIT
------------- ----------- -----------
            0           1           1
            1           0           0

  2 record(s) selected.