From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Greg Stark <gsstark(at)mit(dot)edu> |
Cc: | "Jim C(dot) Nasby" <decibel(at)decibel(dot)org>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Testing concurrent psql |
Date: | 2007-05-17 00:19:51 |
Message-ID: | 10008.1179361191@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Greg Stark <gsstark(at)mit(dot)edu> writes:
> "Jim C. Nasby" <decibel(at)decibel(dot)org> writes:
>> On Wed, May 16, 2007 at 09:43:36AM -0400, Gregory Stark wrote:
>>> I seem to recall there was a way to construct scenarios that returned multiple
>>> result sets via rules but I don't know how to arrange that. Anyone remember?
>>
>> An ALSO SELECT rule?
> It gives you an error.
Not if you do it correctly.
regression=# create table foo(f1 int);
CREATE TABLE
regression=# create rule r1 as on insert to foo do also
regression-# ( select 1; select 2; select 3 );
CREATE RULE
regression=# insert into foo values(42);
?column?
----------
3
(1 row)
INSERT 0 1
regression=#
This shows BTW that PQexec throws away all but the last select-result;
but they are all delivered to the client.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2007-05-17 00:34:57 | Re: [PATCHES] Full page writes improvement, code update |
Previous Message | Bruce Momjian | 2007-05-17 00:09:44 | Re: Lack of urgency in 8.3 reviewing |