pg.ddx.io  pgsql-docs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bruce Momjian <bruce@momjian.us>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Joe Conway <mail@joeconway.com>
Cc: Hackers (PostgreSQL) <pgsql-hackers@postgresql.org>
Subject: Re: Values list-of-targetlists patch for comments (was Re: [PATCHES]
Date: Tue, 1 Aug 2006 23:14:37 -0400 (EDT)
Message-ID: <200608020314.k723EbQ01079@momjian.us> (raw)
In-Reply-To: <28624.1154487120@sss.pgh.pa.us>


Should we wait for someone to actually ask for this before adding it to
the TODO list?  Does it cause a crash now?

---------------------------------------------------------------------------

Tom Lane wrote:
> Joe Conway <mail@joeconway.com> writes:
> > Tom Lane wrote:
> >> What I'm inclined to do for 8.2 is to disallow OLD/NEW references in
> >> multi-element VALUES clauses; the feature is still tremendously useful
> >> without that.
> 
> > Given the timing, this sounds like a reasonable approach. I agree that 
> > the feature has lots of interesting uses -- I'd hate to see us lose 
> > that. Disallowing OLD/NEW references doesn't contradict the spec in any 
> > way AFAIK either.
> 
> I don't think rules are in the spec at all ;-) ... so no, that's not
> a problem.  My example demonstrated a pretty likely use:
> 
> create rule r2 as on update to src do
> 	insert into log values(old.*, 'old'), (new.*, 'new');
> 
> but for the moment we can tell people to work around it the way
> they always have:
> 
> create rule r2 as on update to src do
> 	insert into log select old.*, 'old' union all new.*, 'new';
> 
> or just use two separate INSERT commands in the rule.
> 
> We oughta fix it later, but I don't feel ashamed to have a restriction
> like this in the first cut.
> 
> 			regards, tom lane
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Have you searched our list archives?
> 
>                http://archives.postgresql.org

-- 
  Bruce Momjian   bruce@momjian.us
  EnterpriseDB    http://www.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +



view thread (61+ messages)  latest in thread

Message-ID: <200608020314.k723EbQ01079@momjian.us>
Permalink:  ../200608020314.k723EbQ01079@momjian.us/
Also on:    postgresql.org/message-id/200608020314.k723EbQ01079@momjian.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-docs@postgresql.org
  Cc: bruce@momjian.us, tgl@sss.pgh.pa.us, mail@joeconway.com, pgsql-hackers@postgresql.org
  Subject: Re: Values list-of-targetlists patch for comments (was Re: [PATCHES]
  In-Reply-To: <200608020314.k723EbQ01079@momjian.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox