The
SET CURRENT DEFAULT TRANSFORM GROUP statement changes the value of
the CURRENT DEFAULT TRANSFORM GROUP special register.
This statement is not under transaction control.
Invocation
This statement can be embedded
in an application program or issued through the use of dynamic SQL
statements. It is an executable statement that can be dynamically
prepared.
Authorization
None required.
Syntax
.-CURRENT-.
>>-SET--+---------+--DEFAULT TRANSFORM GROUP-------------------->
.- = -.
>--+-----+--group-name-----------------------------------------><
Description
- group-name
- Specifies a one-part name that identifies a transform group defined
for all structured types. This name can be referenced in subsequent
statements (or until the special register value is changed again using
another SET CURRENT DEFAULT TRANSFORM GROUP statement).
The
name must be an SQL identifier (either ordinary or delimited). No
validation that the group-name is defined
for any structured type is made when the special register is set.
Only when a structured type is specifically referenced is the definition
of the named transform group checked for validity.
Rules
- If the value specified does not conform to the rules for a group-name,
an error is raised (SQLSTATE 42815)
- The TO SQL and FROM SQL functions defined in the group-name transform
group are used for exchanging user-defined structured type data with
a host program.
Usage notes
- The initial value of the CURRENT DEFAULT TRANSFORM GROUP special
register is the empty string.
Example
Set
the default transform group to MYSTRUCT1. The TO SQL and FROM SQL
functions defined in the MYSTRUCT1 transform group will be used for
exchanging user-defined structured type variables with the current
host program.
SET CURRENT DEFAULT TRANSFORM GROUP = MYSTRUCT1