Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 696af9a

Browse files
committed
doc: Document sequence function privileges better
Document the privileges required for each of the sequence functions. This was already in the GRANT reference page, but also add it to the function description for easier reference.
1 parent ab82340 commit 696af9a

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

doc/src/sgml/func.sgml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11723,6 +11723,10 @@ nextval('foo'::text) <lineannotation><literal>foo</literal> is looked up at
1172311723
</para>
1172411724
</important>
1172511725

11726+
<para>
11727+
This function requires <literal>USAGE</literal>
11728+
or <literal>UPDATE</literal> privilege on the sequence.
11729+
</para>
1172611730
</listitem>
1172711731
</varlistentry>
1172811732

@@ -11738,6 +11742,11 @@ nextval('foo'::text) <lineannotation><literal>foo</literal> is looked up at
1173811742
other sessions have executed <function>nextval</function> since the
1173911743
current session did.
1174011744
</para>
11745+
11746+
<para>
11747+
This function requires <literal>USAGE</literal>
11748+
or <literal>SELECT</literal> privilege on the sequence.
11749+
</para>
1174111750
</listitem>
1174211751
</varlistentry>
1174311752

@@ -11754,6 +11763,11 @@ nextval('foo'::text) <lineannotation><literal>foo</literal> is looked up at
1175411763
<function>lastval</function> if <function>nextval</function>
1175511764
has not yet been called in the current session.
1175611765
</para>
11766+
11767+
<para>
11768+
This function requires <literal>USAGE</literal>
11769+
or <literal>SELECT</literal> privilege on the last used sequence.
11770+
</para>
1175711771
</listitem>
1175811772
</varlistentry>
1175911773

@@ -11792,6 +11806,11 @@ SELECT setval('foo', 42, false); <lineannotation>Next <function>nextval</> wi
1179211806
back.
1179311807
</para>
1179411808
</important>
11809+
11810+
<para>
11811+
This function requires <literal>UPDATE</literal> privilege on the
11812+
sequence.
11813+
</para>
1179511814
</listitem>
1179611815
</varlistentry>
1179711816
</variablelist>

0 commit comments

Comments
 (0)