pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: lyonj@EM-Systems.com
To: Cedar Cox <cedarc@visionforisrael.com>
Cc: pgsql-interfaces@postgresql.org
Subject: Re: Re: can't delete record
Date: Wed, 07 Mar 2001 09:49:35 -0500
Message-ID: <3AA64A7F.B59028F9@EM-Systems.com> (raw)
References: <Pine.LNX.4.21.0103071701470.20863-100000@nanu.visionforisrael.com>

I might have read that in Bruce's book.  Any serious PostgreSQL developer
should read it cover to cover!

I agree, plpgsql should return an error if you try to access NEW when
TG_OP='DELETE'.

Jeffrey


Cedar Cox wrote:

> Bingo!  That was it.. Thank you.
>
> BTW, is this behavior documented (no error message)?  It should be.
> Even better, make plpgsql a little nicer ;)
>
> -Cedar
>
> On Wed, 7 Mar 2001, Jeffrey Lyon wrote:
>
> > Do you have a trigger applied against this record on DELETE?  If so, are
> > you returning NEW or OLD?  I think that you need to return NEW on an
> > UPDATE or INSERT and an OLD on DELETE.
> >
> > Jeffrey
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo@postgresql.org so that your
> message can get through to the mailing list cleanly




view thread (5+ messages)  latest in thread

Message-ID: <3AA64A7F.B59028F9@EM-Systems.com>
Permalink:  ../3AA64A7F.B59028F9@EM-Systems.com/
Also on:    postgresql.org/message-id/3AA64A7F.B59028F9@EM-Systems.com

 · 

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-interfaces@postgresql.org
  Cc: lyonj@EM-Systems.com, cedarc@visionforisrael.com
  Subject: Re: Re: can't delete record
  In-Reply-To: <3AA64A7F.B59028F9@EM-Systems.com>

* 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