Re: [HACKERS] an aggregate array function

2003-07-29 Thread Merlin Moncure
Joe Conway wrote: Do you think there would be any use for an aggregate which returns an array of the aggregated (usually simple) type? What exactly have you looked at? In current cvs there is array_append and array_cat. There *was* array_accum, but that was yanked due to an objection that

Re: [HACKERS] an aggregate array function

2003-07-29 Thread Joe Conway
Merlin Moncure wrote: What do you think about the other question about an 'array creating aggregate', is that a useful contribution? Hmm, either I'm not understanding you, or you're not understanding me ;-) First, see contrib/intagg. Second, the following works in 7.4devel: -- create test data

Re: [HACKERS] an aggregate array function

2003-07-29 Thread Dani Oderbolz
Merlin Moncure wrote: Dear hackers, Do you think there would be any use for an aggregate which returns an array of the aggregated (usually simple) type? Has this already been done by anyone? I looked at the source and noticed that for each inserted item, the array utility functions

Re: [HACKERS] an aggregate array function

2003-07-29 Thread Andrew Dunstan
It's in the SQL99 standard. There's nothing forcing you to use them - I am a (possibly) old-fashioned data architect, so I never use them ;-) SQL99 actually allows you to use more or less arbitrary composite types as columns (although Pg currently doesn't) - many would argue that this violates

Re: [HACKERS] an aggregate array function

2003-07-29 Thread Merlin Moncure
Andrew wrote: It's in the SQL99 standard. There's nothing forcing you to use them - I am a (possibly) old-fashioned data architect, so I never use them ;-) SQL99 actually allows you to use more or less arbitrary composite types as columns (although Pg currently doesn't) - many would argue

Re: [HACKERS] an aggregate array function

2003-07-29 Thread Andrew Dunstan
well, (smile) I didn't say *I* saw violation of FNF as an objection. I think my statement is true - many would see it as a violation of FNF. Many others like you might argue differently. I first got into this business nearly 20 years ago when I came to realise the severe limitations of the

Re: [HACKERS] an aggregate array function

2003-07-28 Thread Joe Conway
Merlin Moncure wrote: Dear hackers, Do you think there would be any use for an aggregate which returns an array of the aggregated (usually simple) type? Has this already been done by anyone? I looked at the source and noticed that for each inserted item, the array utility functions perform a