From: | "Merlin Moncure" <mmoncure(at)gmail(dot)com> |
---|---|
To: | "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: WITH RECURSIVE ... CYCLE in vanilla SQL: issues with arrays of rows |
Date: | 2008-10-08 13:26:17 |
Message-ID: | b42b73150810080626v2256facay9d865ee680bcdd1@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Tue, Oct 7, 2008 at 9:58 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> * Instead of the above, we could try to make
> ROW(some columns) = ANY (array variable)
> work. This is shorter than the above syntax and would presumably have
> a lot less overhead too. But it doesn't work right now, not even for
> named rowtypes much less anonymous ones.
By extension, would this also mean things like
select row(1,2,3)::foo = foo from foo;
or
select (1,2,3)::foo = (1,2,3)::foo;
or
select (1,2,3) = (1,2,3)::foo;
Would work (presumably as row-wise comparison does)? Also,
create index foo_idx on foo(foo);
select * from foo where (1,2,3)::foo = foo;
would be very nice.
> I'm thinking that addressing these pieces would be a generally good
> thing to do, above and beyond potential uses in recursive queries.
absolutely.
merlin
From | Date | Subject | |
---|---|---|---|
Next Message | Simon Riggs | 2008-10-08 13:34:58 | Re: [PATCHES] Infrastructure changes for recovery (v8) |
Previous Message | Tom Lane | 2008-10-08 13:23:11 | Re: Transactions and temp tables |