Re: is any reason why only one columns subselect are allowed in array()?
В списке pgsql-hackers по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: is any reason why only one columns subselect are allowed in array()? |
| Дата | |
| Msg-id | 21990.1227031328@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: is any reason why only one columns subselect are allowed in array()? (Sam Mason <sam@samason.me.uk>) |
| Ответы |
Re: is any reason why only one columns subselect are allowed in array()?
|
| Список | pgsql-hackers |
Sam Mason <sam@samason.me.uk> writes:
> I've used this syntax before and got a surprising message back. I'd
> expect to be able to do the following:
> ARRAY((SELECT col1, col2 FROM (VALUES ('a',1), ('b',2)) x(col1,col2)));
> and get the following back {"(a,1)","(b,2)"}. So I think I'm with
> David.
I concur --- if we support something like this, the behavior should be
that you get an array of record. Pavel's proposal for a 2-D array seems
unworkably restrictive. And I certainly don't want to end up in a
situation where we return either a 2-D array or array of record
depending on whether the parser thinks the column data types match ...
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера