User-defined data type: Based on the system data type, it is generated by the database administrator.
Use system stored procedures to define user-defined data types` Sp_addtype [@typename=] new data type name, [@phystype=] system data type name [,[@nulltype=] null_type] [,[@owner=] owner_name] system Data type names, except "BIG, INT, SMALLINT, TEXT, DATETIME, REAL, UNIQUE IDENTIFIER, IMAGE", must be enclosed in single quotes. null_type: The way the new data type handles null values, it can be NOT NULL or NULL, the default is null owner_name: The owner of the new data type, the default is the current user.
E.g:
/* Create custom data type */ Exec sp_addtype a, ' char(10) ' Exec sp_addtype da, datetime , ' null ' /* Delete custom data type */ Exec sp_droptype a