diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2016-01-05 13:02:43 -0500 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2016-01-05 13:02:43 -0500 |
commit | ea0d494dae0d3d6fce26bf5d6fbaa07e2ee6c402 (patch) | |
tree | 48a2fcde511e2a8ec9870b614fd8e7f04f2bad6c /doc/src | |
parent | efa318bcfac132c48dff8196f726e56a6843f06b (diff) | |
download | postgresql-ea0d494dae0d3d6fce26bf5d6fbaa07e2ee6c402.tar.gz postgresql-ea0d494dae0d3d6fce26bf5d6fbaa07e2ee6c402.zip |
Make the to_reg*() functions accept text not cstring.
Using cstring as the input type was a poor decision, because that's not
really a full-fledged type. In particular, it lacks implicit coercions
from text or varchar, meaning that usages like to_regproc('foo'||'bar')
wouldn't work; basically the only case that did work without explicit
casting was a simple literal constant argument.
The lack of field complaints about this suggests that hardly anyone
is using these functions, so hopefully fixing it won't cause much of
a compatibility problem. They've only been there since 9.4, anyway.
Petr Korobeinikov
Diffstat (limited to 'doc/src')
-rw-r--r-- | doc/src/sgml/func.sgml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml index 4ce634cc299..a0b42c2ddbd 100644 --- a/doc/src/sgml/func.sgml +++ b/doc/src/sgml/func.sgml @@ -16173,7 +16173,7 @@ SELECT collation for ('foo' COLLATE "de_DE"); <function>to_regoperator</function>, <function>to_regtype</function>, <function>to_regnamespace</function>, and <function>to_regrole</function> functions translate relation, function, operator, type, schema, and role - names to objects of + names (given as <type>text</>) to objects of type <type>regclass</>, <type>regproc</>, <type>regprocedure</type>, <type>regoper</>, <type>regoperator</type>, <type>regtype</>, <type>regnamespace</>, and <type>regrole</> |