-DISPLAY FUNCTION SPECIFIC command (Db2)

The Db2 command DISPLAY FUNCTION SPECIFIC displays statistics about external user-defined functions that Db2 applications access.

Abbreviation: -DIS FUNC SPEC

Environment

This command can be issued from a z/OS® console, a DSN session under TSO, a DB2I panel (DB2 COMMANDS), an IMS or CICS® terminal, or a program using the instrumentation facility interface (IFI).

Data sharing scope: Group or member

Authorization

To run this command, you must use a privilege set of the process that includes one of the following authorities for each function:
  • DISPLAY privilege
  • System DBADM authority
  • SYSOPR authority
  • SYSCTRL authority
  • SYSADM authority
If you specify DISPLAY FUNCTION SPECIFIC *.* or schema.partial-name *, you must use a privilege set of the process that includes one of the following authorities:
  • SYSOPR authority
  • SYSCTRL authority
  • SYSADM authority

Db2 commands that are issued from a logged-on z/OS console or TSO SDSF can be checked by Db2 authorization using primary and secondary authorization IDs. Start of changeA logged-on z/OS user ID must be defined in RACF or a similar security server.End of change

If you are using an external security product to authorize usage of DISPLAY FUNCTION SPECIFIC, define SYSOPR as a user to the external security product for those cases in which DISPLAY FUNCTION SPECIFIC SCOPE(GROUP) runs on a remote system and SYSOPR is used as the authorization ID.

Syntax

Read syntax diagramSkip visual syntax diagramDISPLAY FUNCTION SPECIFIC( *.*)(,schema.specific-function-nameschema.partial-name*)SCOPE(LOCALGROUP)

Option descriptions

schema.specific-function-name
Displays information for the specific named function in the specified schema. You cannot specify a function name as you can in SQL; you must use the specific name. If a specific name was not specified on the CREATE FUNCTION statement, query SYSIBM.SYSROUTINES for the correct specific name:
SELECT SPECIFICNAME, PARM_COUNT
  FROM SYSIBM.SYSROUTINES
   WHERE NAME='function_name'
    AND SCHEMA='schema_name';
 
For overloaded functions, this query can return multiple rows.
schema.partial-name*
Displays information for a set of functions in the specified schema.

The specific names of all functions in the set begin with partial-name and can end with any string, including the empty string. For example, schema1.ABC* displays information for all functions with specific names that begin with ABC in schema1.

(*.*)
Displays information for all functions that Db2 applications have accessed since the Db2 subsystem was started.
SCOPE
Specifies the scope of the command.
( LOCAL )
Specifies that the display includes information from only the local member.
(GROUP)
Specifies that the display includes information from all members of the data sharing group.

Usage notes

Displaying information for all functions
If you do not specify a partial or specific function name, Db2 displays information for all functions that Db2 applications have accessed since the Db2 subsystem was started.
Built-in functions or user-defined functions that are sourced on another function
This command does not apply to built-in functions or user-defined functions that are sourced on another function.
Displaying SQL functions

SQL functions are displayed in the DISPLAY FUNCTION SPECIFIC output only if you invoke the function in debug mode. In that case, the WLM environment column in the output contains the WLM environment that you specified for debugging when you created the SQL function.

The DISPLAY FUNCTION output shows the statistics on an SQL function as '0' if the function is under the effect of a STOP FUNCTION command.

Trace information for commands issued with group scope
If this command is issued with options that specify group scope in a Db2 data sharing member, it also runs on all other active members. IFICID 090 trace records for other group members can show that the same command was issued by the SYSOPR authorization ID from the 016.TLPKN5F correlation ID, in addition to the trace records from the member where the original command was issued. See Command scope in Db2 data sharing.

Output

Message DSNX975I indicates the beginning of the output of the command.

Examples

Example: Displaying information about all user-defined functions in a schema
The following command displays information about all functions in the PAYROLL schema and the HRPROD schema.
-DISPLAY FUNCTION SPECIFIC(PAYROLL.*, HRPROD.*)

The output is similar to the following output:

DSNX975I = DSNX9DIS DISPLAY FUNCTION SPECIFIC REPORT FOLLOWS-

------ SCHEMA=PAYROLL
FUNCTION        STATUS      ACTIVE   QUED   MAXQ   TIMEOUT   FAIL    WLM_ENV
PAYRFNC1        STARTED       0       0       1       0       0      WLMENV1
PAYRFNC2        STOPQUE       0       5       5       3       0      WLMENV1
PAYRFNC3        STARTED       2       0       6       0       0      WLMENV1
USERFNC4        STOPREJ       0       0       1       0       0      WLMENV3
 
------ SCHEMA=HRPROD
FUNCTION        STATUS      ACTIVE   QUED   MAXQ   TIMEOUT   FAIL    WLM_ENV
HRFNC1          STARTED       0       0       1       0       0      WLMENV2
HRFNC2          STOPREJ       0       0       1       0       0      WLMENV2
DSNX9DIS DISPLAY FUNCTION SPECIFIC REPORT COMPLETE
DSN9022I = DSNX9COM '-DISPLAY FUNC' NORMAL COMPLETION
Example: Displaying information about selected user-defined functions in a schema
The following command displays information about functions USERFNC2 and USERFNC4 in the PAYROLL schema.
-DISPLAY FUNCTION SPECIFIC(PAYROLL.USERFNC2,PAYROLL.USERFNC4)

The output is similar to the following output:

DSNX975I = DSNX9DIS DISPLAY FUNCTION SPECIFIC REPORT FOLLOWS-
 
------ SCHEMA=PAYROLL
FUNCTION        STATUS      ACTIVE   QUED   MAXQ   TIMEOUT   FAIL    WLM_ENV
USERFNC2        STOPQUE       0       5       5       3       0      WLMENV3
USERFNC4        STOPREJ       0       0       1       0       0      WLMENV3
DSNX9DIS DISPLAY FUNCTION SPECIFIC REPORT COMPLETE
DSN9022I = DSNX9COM '-DISPLAY FUNC' NORMAL COMPLETION
Example: Displaying information about stopped user-defined functions
Suppose that you issue the following commands:
-STOP FUNCTION SPECIFIC(SYSADM.FN*) ACTION(QUEUE)
-DISPLAY FUNCTION SPECIFIC(SYSADM.*)

The output looks similar to the following output:

DSNX975I = DSNX9DIS DISPLAY FUNCTION SPECIFIC REPORT FOLLOWS-
 
------ SCHEMA=SYSADM
FUNCTION       STATUS    ACTIVE   QUED  MAXQ  TIMEOUT  FAIL   WLM_ENV
FNC1           STOPQUE     0       0     0       0      0     WLMENV1
FNC2           STOPQUE     0       0     0       0      0     WLMENV3
DSNX9DIS FUNCTIONS FN - FN* STOP QUEUE
DSNX9DIS DISPLAY FUNCTION SPECIFIC REPORT COMPLETE
DSN9022I = DSNX9COM '-DISPLAY FUNC' NORMAL COMPLETION