Pavel Stehule <[email protected]> writes:
> 2017-11-19 18:57 GMT+01:00 Brahmam Eswar <[email protected]>:
>> How to collect multiple columns into array which is composite data type of
>> all select colums
> SELECT ARRAY(SELECT ROW(col1, col2, ...) INTO
You probably need an explicit cast to the rowtype. That is,
declare myarray rowtypename[];
...
select array(select row(col1, ...)::rowtypename from ...) into myarray;
regards, tom lane
--
Sent via pgsql-general mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general