↑↓ select ↵ open ⌫ change scope Open full search

PG.CENTER connects PostgreSQL documentation, reference, and ecosystem knowledge. Maintained by Pigsty.

Functions / Set Returning Functions

generate_subscripts

Read the PG 18 manual

Generates a series comprising the valid subscripts of the dim'th dimension of the given array.

Reading PG 18current·documented in 19 of 27 versions, 8.4 to 20

Signatures & examples

generate_subscripts ( array anyarray, dim integer ) → setof integer
Generates a series comprising the valid subscripts of the dim'th dimension of the given array.
generate_subscripts ( array anyarray, dim integer, reverse boolean ) → setof integer
Generates a series comprising the valid subscripts of the dim'th dimension of the given array. When reverse is true, returns the series in reverse order.
Version history 2
  1. 12 → 13 changed
  2. 8.3 → 8.4 added

Definition snapshot: b7bd9cda · English manual source