type

ARRAY

PostgreSQL arrays store elements of a common type. Ordinary constructed arrays start at index one; other lower bounds are possible. Example target: PostgreSQL 17. Run in a disposable database; examples need no existing tables.

Formal Syntax & Structure

sql syntaxsql
element_type[]

Working Example

Example Snippetsql
SELECT (ARRAY[10,20,30])[2];
SQL Reference