Re: [GENERAL] How to explode an array into multiple rows

2005-08-05 Thread Tom Lane
Kevin Murphy <[EMAIL PROTECTED]> writes: > I'd like to do something like this: > select array_explode(array_col) from table1 where col2 = 'something'; > where array_explode returns the elements of array_col unpacked onto > separate rows. > I tried creating a function returning a setof type, but p

[GENERAL] How to explode an array into multiple rows

2005-08-04 Thread Kevin Murphy
I'd like to do something like this: select array_explode(array_col) from table1 where col2 = 'something'; where array_explode returns the elements of array_col unpacked onto separate rows. I tried creating a function returning a setof type, but postgresql produces a "set-valued function call