Entering content frame

Value Specification (extended_value_spec) Locate the document in its SAP Library structure

Values can be specified (extended_value_spec) by values (value_spec: literals, parameter specifications, or a series of keywords) or by one of the keywords DEFAULT or STAMP.

Syntax

<extended value spec> ::= <value spec> | DEFAULT | STAMP

<value_spec> ::= <literal>
| <
parameter_spec
>
| NULL
| USER | USERGROUP
| SYSDBA | UID
| [<
schema_name
>.]<sequence_name>.NEXTVAL
| [<schema_name>.]<sequence_name>.CURRVAL
| <
table_name
>.CURRVAL
| DATE | TIME | TIMESTAMP
| UTCDATE | TIMEZONE | UTCDIFF
| TRUE | FALSE
| TRANSACTION

Explanation

DEFAULT

DEFAULT identifies the default value for the column in a CREATE TABLE statement or ALTER TABLE statement. DEFAULT cannot be used to specify values if one of these values is not defined.

The DEFAULT keyword can be used in the following SQL statements: INSERT Statement, UPDATE Statement

The DEFAULT keyword can be used in a DEFAULT predicate.

STAMP

The database system is able to generate unique values. Such numbers are serial numbers beginning at X'000000000001' and are assigned in ascending order. It cannot be ensured that a sequence of values is uninterrupted. The STAMP keyword supplies the next value generated by the database system.

The STAMP keyword can be used in the following SQL statements (only for columns of data type CHAR(n) BYTE where n>=8, see DEFAULT Specification): INSERT Statement, UPDATE Statement

If the user wants to find out the generated value before it is applied to a column, the following SQL statement must be used:
NEXT STAMP Statement

<value_spec>

NULL

Specification of the NULL value.

USER|USERGROUP

Current user name or name of the user group to which the user calling the SQL statement belongs. If the user does not belong to a user group, the user name is displayed.

SYSDBA

Specification of the database system administrator.

UID

Identification of the current user. This is an integer.

[<schema_name>.]<sequence_name>.NEXTVAL

Next value generated for the specified sequence name (of the schema in question).

[<schema_name>.]<sequence_name>.CURRVAL

Last value generated for the specified sequence name, using [<schema_name>.]<sequence_name>.NEXTVAL.

<table_name>.CURRVAL

Last value assigned in the current database session for the serial column in the table table_name.

DATE|TIME|TIMESTAMP

Current date, time, time stamp.

UTCDATE

Current UTC time stamp (Greenwich Mean Time)

TIMEZONE

Time difference in hours in the format hhmmss (in data type FIXED(6)) between your local time value and the UTC time value.

UTCDIFF

Time difference in hours (in data type FIXED(4,2)) between your local time and the UTC time value.

TRUE|FALSE

Corresponding value of a column of the data type BOOLEAN.

TRANSACTION

Identification of the current transaction. This is a value of data type CHAR(10) BYTE.

 

Leaving content frame