How to split an array into columns

Поиск
Список
Период
Сортировка
От a
Тема How to split an array into columns
Дата
Msg-id tencent_457E571D2754843359EF7ABA@qq.com
обсуждение исходный текст
Ответы Re: How to split an array into columns  (Thomas Kellerer <spam_eater@gmx.net>)
Re: How to split an array into columns  (Paul A Jungwirth <pj@illuminatedcomputing.com>)
Список pgsql-general
Say if I have an float8 array:

id| data
--|---------------
a | {1,2}
b | {2,4}

If I could using query to make it looks like this:

id| data[1] | data[2]
--|----------|-----------
a |      1      |     2
b |      2      |     4

Since I would have around 200,000 rows, I would prefer it having enough capacity to carry out the calculation such as sum().

Thank you so much!

В списке pgsql-general по дате отправления:

Предыдущее
От: Durumdara
Дата:
Сообщение: Re: Hungarian collation in English Windows server
Следующее
От: Thomas Kellerer
Дата:
Сообщение: Re: How to split an array into columns