Extend the data type system

You can extend the data type system by writing routines that provide the following additional behavior for existing built-in or extended data types:
  • Define operators to provide additional operations on data types.
  • Define operator classes to provide new functionality for a secondary-access method (an index) on a data type.
  • Define casts to provide conversions between data types.
  • Define functions that provide information for the optimizer.

You must register each new function in the database with the CREATE FUNCTION statement.

If you plan to enable the implicit or explicit execution of a UDR across databases, all user-defined data types and casts must be defined in all of the participating databases of the same database server instance.