@@ -982,6 +982,15 @@ createTypeCompositeFrom ty = createTypeComposite ty
982 :: NP (Aliased (TypeExpression schemas)) (RowPG hask))
982 :: NP (Aliased (TypeExpression schemas)) (RowPG hask))
985+`createDomain` creates a new domain. A domain is essentially a data type
986+with constraints (restrictions on the allowed set of values).
988+Domains are useful for abstracting common constraints on fields
989+into a single location for maintenance. For example, several tables might
990+contain email address columns, all requiring the same `check` constraint
991+to verify the address syntax. Define a domain rather than setting up
992+each table's constraint individually.
987 createPositive :: Definition (Public '[]) (Public '["positive" ::: 'Typedef 'PGfloat4])
996 createPositive :: Definition (Public '[]) (Public '["positive" ::: 'Typedef 'PGfloat4])