1
0
mirror of https://github.com/postgres/postgres.git synced 2025-12-19 17:02:53 +03:00

SQL/MED catalog manipulation facilities

This doesn't do any remote or external things yet, but it gives modules
like plproxy and dblink a standardized and future-proof system for
managing their connection information.

Martin Pihlak and Peter Eisentraut
This commit is contained in:
Peter Eisentraut
2008-12-19 16:25:19 +00:00
parent 1eec10a2de
commit cae565e503
76 changed files with 8452 additions and 125 deletions

View File

@@ -1,4 +1,4 @@
<!-- $PostgreSQL: pgsql/doc/src/sgml/func.sgml,v 1.462 2008/12/18 18:20:33 tgl Exp $ -->
<!-- $PostgreSQL: pgsql/doc/src/sgml/func.sgml,v 1.463 2008/12/19 16:25:16 petere Exp $ -->
<chapter id="functions">
<title>Functions and Operators</title>
@@ -11335,6 +11335,21 @@ SET search_path TO <replaceable>schema</> <optional>, <replaceable>schema</>, ..
<entry><type>boolean</type></entry>
<entry>does current user have privilege for database</entry>
</row>
<row>
<entry><literal><function>has_foreign_data_wrapper_privilege</function>(<parameter>user</parameter>,
<parameter>fdw</parameter>,
<parameter>privilege</parameter>)</literal>
</entry>
<entry><type>boolean</type></entry>
<entry>does user have privilege for foreign-data wrapper</entry>
</row>
<row>
<entry><literal><function>has_foreign_data_wrapper_privilege</function>(<parameter>fdw</parameter>,
<parameter>privilege</parameter>)</literal>
</entry>
<entry><type>boolean</type></entry>
<entry>does current user have privilege for foreign-data wrapper</entry>
</row>
<row>
<entry><literal><function>has_function_privilege</function>(<parameter>user</parameter>,
<parameter>function</parameter>,
@@ -11380,6 +11395,21 @@ SET search_path TO <replaceable>schema</> <optional>, <replaceable>schema</>, ..
<entry><type>boolean</type></entry>
<entry>does current user have privilege for schema</entry>
</row>
<row>
<entry><literal><function>has_server_privilege</function>(<parameter>user</parameter>,
<parameter>server</parameter>,
<parameter>privilege</parameter>)</literal>
</entry>
<entry><type>boolean</type></entry>
<entry>does user have privilege for foreign server</entry>
</row>
<row>
<entry><literal><function>has_server_privilege</function>(<parameter>server</parameter>,
<parameter>privilege</parameter>)</literal>
</entry>
<entry><type>boolean</type></entry>
<entry>does current user have privilege for foreign server</entry>
</row>
<row>
<entry><literal><function>has_table_privilege</function>(<parameter>user</parameter>,
<parameter>table</parameter>,
@@ -11435,12 +11465,18 @@ SET search_path TO <replaceable>schema</> <optional>, <replaceable>schema</>, ..
<indexterm>
<primary>has_function_privilege</primary>
</indexterm>
<indexterm>
<primary>has_foreign_data_wrapper_privilege</primary>
</indexterm>
<indexterm>
<primary>has_language_privilege</primary>
</indexterm>
<indexterm>
<primary>has_schema_privilege</primary>
</indexterm>
<indexterm>
<primary>has_server_privilege</primary>
</indexterm>
<indexterm>
<primary>has_table_privilege</primary>
</indexterm>
@@ -11478,6 +11514,14 @@ SELECT has_function_privilege('joeuser', 'myfunc(int, text)', 'execute');
</programlisting>
</para>
<para>
<function>has_foreign_data_wrapper_privilege</function> checks whether a user
can access a foreign-data wrapper in a particular way. The possibilities for its
arguments are analogous to <function>has_table_privilege</function>.
The desired access privilege type must evaluate to
<literal>USAGE</literal>.
</para>
<para>
<function>has_language_privilege</function> checks whether a user
can access a procedural language in a particular way. The possibilities
@@ -11495,6 +11539,14 @@ SELECT has_function_privilege('joeuser', 'myfunc(int, text)', 'execute');
<literal>USAGE</literal>.
</para>
<para>
<function>has_server_privilege</function> checks whether a user
can access a foreign server in a particular way. The possibilities for its
arguments are analogous to <function>has_table_privilege</function>.
The desired access privilege type must evaluate to
<literal>USAGE</literal>.
</para>
<para>
<function>has_table_privilege</function> checks whether a user
can access a table in a particular way. The user can be