aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2004-03-19 19:13:26 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2004-03-19 19:13:26 +0000
commit6c7e6d2baa509cb71f46b323191194a88745e7d3 (patch)
tree6a648a41ec2ece2ef04512e318400472975458f1
parent0fdc6c4cc0a1b84844caa29b5a8fb6cb5f28b752 (diff)
downloadpostgresql-6c7e6d2baa509cb71f46b323191194a88745e7d3.tar.gz
postgresql-6c7e6d2baa509cb71f46b323191194a88745e7d3.zip
Add a usage example for has_function_privilege().
-rw-r--r--doc/src/sgml/func.sgml10
1 files changed, 7 insertions, 3 deletions
diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml
index 68d0a8a9540..ccd430a97ff 100644
--- a/doc/src/sgml/func.sgml
+++ b/doc/src/sgml/func.sgml
@@ -1,5 +1,5 @@
<!--
-$PostgreSQL: pgsql/doc/src/sgml/func.sgml,v 1.194 2004/03/10 20:10:26 neilc Exp $
+$PostgreSQL: pgsql/doc/src/sgml/func.sgml,v 1.195 2004/03/19 19:13:26 tgl Exp $
PostgreSQL documentation
-->
@@ -6881,15 +6881,19 @@ SELECT has_table_privilege('myschema.mytable', 'select');
arguments are analogous to <function>has_table_privilege</function>.
When specifying a function by a text string rather than by OID,
the allowed input is the same as for the <type>regprocedure</> data type.
- The desired access privilege type must currently evaluate to
+ The desired access privilege type must evaluate to
<literal>EXECUTE</literal>.
+ An example is:
+<programlisting>
+SELECT has_function_privilege('joeuser', 'myfunc(int, text)', 'execute');
+</programlisting>
</para>
<para>
<function>has_language_privilege</function> checks whether a user
can access a procedural language in a particular way. The possibilities
for its arguments are analogous to <function>has_table_privilege</function>.
- The desired access privilege type must currently evaluate to
+ The desired access privilege type must evaluate to
<literal>USAGE</literal>.
</para>