Commit 06eba0fd authored by Bruce Momjian's avatar Bruce Momjian

doc: improve description of subscripting of arrays

It wasn't clear the non-integers are cast to integers for subscripting,
rather than throwing an error.

Reported-by: sean@materialize.io

Discussion: https://postgr.es/m/159538675800.624.7728794628229799531@wrigleys.postgresql.org

Backpatch-through: 9.5
parent 47c427d0
...@@ -1359,7 +1359,7 @@ CREATE FUNCTION dept(text) RETURNS dept ...@@ -1359,7 +1359,7 @@ CREATE FUNCTION dept(text) RETURNS dept
</synopsis> </synopsis>
(Here, the brackets <literal>[ ]</literal> are meant to appear literally.) (Here, the brackets <literal>[ ]</literal> are meant to appear literally.)
Each <replaceable>subscript</replaceable> is itself an expression, Each <replaceable>subscript</replaceable> is itself an expression,
which must yield an integer value. which will be rounded to the nearest integer value.
</para> </para>
<para> <para>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment