Background documentationParameter Specification (parameter_spec) Locate this document in the navigation structure

 

A parameter specification (parameter_spec) identifies the parameter name and, if necessary, the indicator name that are necessary to specify a parameter.

Structure

Syntax Syntax

  1. <parameter_spec> ::=
      <parameter_name> [<indicator_name>]
End of the code.
Explanation

The indicator must be declared as a variable in the embedding programming language. It must be possible to assign at least four-digit integers to this variable.

A distinction is made between output parameters and input parameters:

  • Output parameters: Parameters that are to receive values retrieved from the database system.

    - An indicator with the value Null indicates that the transferred value is not a NULL value and that the parameter value is the transferred value.

    - An indicator with the value –1 indicates that the parameter value is the NULL value.

    - Alphanumeric output parameters: An indicator with a value greater than 0 indicates that the assigned character string was too long and has been truncated. The indicator shows the length of the original output column from the character string.

    - Numeric output parameters: An indicator with a value greater than 0 indicates that the assigned value has too many significant digits and decimal places have been truncated. The indicator indicates the number of digits in the original value.

    - For numeric output parameters, an indicator with the value –2 indicates that the parameter value is the special NULL value.

  • Input parameters: Parameters containing values that are to be transferred to the database system.

    - An indicator with a value greater than or equal to 0 indicates that the specified parameter value is the value that is to be transferred to the database system.

    - An indicator with a value less than 0 indicates that the specified parameter value is the NULL value.