Create a new domain - postgres docs
Arguments:
domain_name
[Name] - name of the new domaintype
[string] - type of the new domainoptions
[object] - options:default
[string] - default value of domaincollation
[string] - collation of data typenotNull
[boolean] - sets NOT NULL if true (not recommended)check
[string] - sql for a check constraint for this columnconstraintName
[string] - name for constraint
Reverse Operation: dropDomain
Drop a domain - postgres docs
Arguments:
domain_name
[Name] - name of the the domain to dropdrop_options
[object] - options:ifExists
[boolean] - drops domain only if it existscascade
[boolean] - drops also dependent objects
Alter a domain - postgres docs
Arguments:
domain_name
[Name] - name of the new domainoptions
[object] - options:default
[string] - default value of domaincollation
[string] - collation of data typenotNull
[boolean] - sets NOT NULL if true or NULL if falseallowNull
[boolean] - sets NULL if true (alternative tonotNull
)check
[string] - sql for a check constraint for this columnconstraintName
[string] - name for constraint
Rename a domain - postgres docs
Arguments: