Pertimbangkan pemeran lengkap Western ini sebelum Anda menghapusnya:
WITH tbl(arr) AS (SELECT (ARRAY[[10,11],[20,21]]))
SELECT arr[2][1] AS the_good
,arr[1] AS the_bad
,arr[1:1] AS the_ugly -- first slice of 2D-array
,arr[1][1:2] AS the_ugly_twin -- 2D-array with elements 1 & 2 of 1st slice
,ARRAY((SELECT unnest(arr[1:1]))) AS the_righteous -- 1D-array of 1st slice
FROM tbl;
->sqlfiddle dengan lebih banyak contoh.
Beberapa latar belakang dalam manual di sini dan di sini .