diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2005-05-01 18:56:19 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2005-05-01 18:56:19 +0000 |
commit | 6c412f0605afeb809014553ff7ad28cf9ed5526b (patch) | |
tree | 5540a678c19dcfa1a7023e0f59a970fe2a9a79ee /doc/src | |
parent | ae793ff63cb9167ea6d0f24ca018ffabad157ece (diff) | |
download | postgresql-6c412f0605afeb809014553ff7ad28cf9ed5526b.tar.gz postgresql-6c412f0605afeb809014553ff7ad28cf9ed5526b.zip |
Change CREATE TYPE to require datatype output and send functions to have
only one argument. (Per recent discussion, the option to accept multiple
arguments is pretty useless for user-defined types, and would be a likely
source of security holes if it was used.) Simplify call sites of
output/send functions to not bother passing more than one argument.
Diffstat (limited to 'doc/src')
-rw-r--r-- | doc/src/sgml/ref/create_type.sgml | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/doc/src/sgml/ref/create_type.sgml b/doc/src/sgml/ref/create_type.sgml index e2276ae5abe..69899d84f53 100644 --- a/doc/src/sgml/ref/create_type.sgml +++ b/doc/src/sgml/ref/create_type.sgml @@ -1,5 +1,5 @@ <!-- -$PostgreSQL: pgsql/doc/src/sgml/ref/create_type.sgml,v 1.54 2005/01/04 00:39:53 tgl Exp $ +$PostgreSQL: pgsql/doc/src/sgml/ref/create_type.sgml,v 1.55 2005/05/01 18:56:17 tgl Exp $ PostgreSQL documentation --> @@ -107,13 +107,10 @@ CREATE TYPE <replaceable class="parameter">name</replaceable> ( (or the type's own OID for a composite type), and the third is the <literal>typmod</> of the destination column, if known (-1 will be passed if not). - The input function should return a value of the data type itself. - The output function may be - declared as taking one argument of the new data type, or as taking - two arguments of which the second is type <type>oid</type>. - The second argument is again the array element type OID for array types - or the type OID for composite types. - The output function should return type <type>cstring</type>. + The input function must return a value of the data type itself. + The output function must be + declared as taking one argument of the new data type. + The output function must return type <type>cstring</type>. </para> <para> @@ -137,11 +134,8 @@ CREATE TYPE <replaceable class="parameter">name</replaceable> ( <replaceable class="parameter">send_function</replaceable> converts from the internal representation to the external binary representation. If this function is not supplied, the type cannot participate in binary - output. The send function may be - declared as taking one argument of the new data type, or as taking - two arguments of which the second is type <type>oid</type>. - The second argument is again the array element type OID for array types - or the type OID for composite types. + output. The send function must be + declared as taking one argument of the new data type. The send function must return type <type>bytea</type>. </para> |