From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Chapman Flack <chap(at)anastigmatix(dot)net> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: regproc and when to schema-qualify |
Date: | 2017-06-11 16:35:04 |
Message-ID: | 21477.1497198904@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Chapman Flack <chap(at)anastigmatix(dot)net> writes:
> The manual says regproc "will display schema-qualified names on output
> if the object would not be found in the current search path without
> being qualified."
That's less than the full truth :-(
> Is regproc displaying the schema in this case because there are two
> overloaded flavors of ginarrayextract, though both are in pg_catalog?
Yes, see the test in regprocout:
* Would this proc be found (uniquely!) by regprocin? If not,
* qualify it.
Of course, in a situation like this, schema-qualification is not enough to
save the day; regprocin will still fail because the name is ambiguous.
You really need to use regprocedure not regproc if you want any guarantees
about the results.
(The fact that we have regproc at all is a bit of a historical accident,
caused by some limitations of the bootstrap mode.)
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Geoghegan | 2017-06-11 17:27:16 | Re: TPC-H Q20 from 1 hour to 19 hours! |
Previous Message | Dean Rasheed | 2017-06-11 16:10:34 | Re: Make ANALYZE more selective about what is a "most common value"? |