Re: RETURNING and DO INSTEAD ... Intentional or not? - Mailing list pgsql-hackers

From Josh Berkus
Subject Re: RETURNING and DO INSTEAD ... Intentional or not?
Date
Msg-id 200709121058.02019.josh@agliodbs.com
Whole thread Raw
In response to Re: RETURNING and DO INSTEAD ... Intentional or not?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tom,

> What the RETURNING clause in the rule does is let you define the data
> that should be returned if the rewritten INSERT had a returning clause
> to start with.

Hmmm.  Aha, that works:

postgres=# insert into test values ( 'mary' ) returning test1;test1
-------mary

So, this should probably be documented to avoid confusion like mine.  Will 
write something up ...

-- 
Josh Berkus
PostgreSQL @ Sun
San Francisco


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: RETURNING and DO INSTEAD ... Intentional or not?
Next
From: Richard Huxton
Date:
Subject: Re: RETURNING and DO INSTEAD ... Intentional or not?