Constructor functions for structured types

When you create a structured type, Db2® creates a function of the same name as the type is created. This function has no parameters and returns an instance of the type with all of its attributes set to null.

The function that is created for structured type Person_t, for example, has the following format:
   CREATE FUNCTION Person_t ( ) RETURNS Person_t
For the subtype Manager_t, a constructor with the following format is created:
   CREATE FUNCTION Manager_t ( ) RETURNS Manager_t

To construct an instance of a type to insert into a column, use the constructor function with the mutator methods. If the type is stored in a table, rather than a column, you do not have to use the constructor function with the mutator methods to insert an instance of a type.