From: Tom Lane Date: Sun, 17 Apr 2011 21:05:51 +0000 (-0400) Subject: Document COLLATE option in CREATE TYPE reference page. X-Git-Url: http://git.postgresql.org/gitweb/static/gitweb.js?a=commitdiff_plain;h=2d4617126f6d708c5777b378d9ef282fb2c08930;p=users%2Fbernd%2Fpostgres.git Document COLLATE option in CREATE TYPE reference page. Curiously, it was already documented in ALTER TYPE ADD ATTRIBUTE, but not here. --- diff --git a/doc/src/sgml/ref/create_type.sgml b/doc/src/sgml/ref/create_type.sgml index f5527d8981..98e1764b1e 100644 --- a/doc/src/sgml/ref/create_type.sgml +++ b/doc/src/sgml/ref/create_type.sgml @@ -22,7 +22,7 @@ PostgreSQL documentation CREATE TYPE name AS - ( [ attribute_name data_type [, ... ] ] ) + ( [ attribute_name data_type [ COLLATE collation ] [, ... ] ] ) CREATE TYPE name AS ENUM ( [ 'label' [, ... ] ] ) @@ -77,11 +77,12 @@ CREATE TYPE name The first form of CREATE TYPE creates a composite type. The composite type is specified by a list of attribute names and data types. - This is essentially the same as the row type + An attribute's collation can be specified too, if its data type is + collatable. A composite type is essentially the same as the row type of a table, but using CREATE TYPE avoids the need to create an actual table when all that is wanted is to define a type. - A stand-alone composite type is useful as the argument or return type of a - function. + A stand-alone composite type is useful, for example, as the argument or + return type of a function.