From: Josh Berkus <josh@agliodbs.com>
To: Greg Patnude <GPatnude@adelphia.net>
To: pgsql-general@postgresql.org
To: pgsql-sql@postgresql.org
Subject: Re: [SQL] Why must the function that a trigger calls return "opaque" ???
Date: Thu, 29 Aug 2002 11:05:25 -0700
Message-ID: <200208291105.25725.josh@agliodbs.com> (raw)
In-Reply-To: <akle4r$2nq5$1@news.hub.org>
References: <akle4r$2nq5$1@news.hub.org>
Greg,
> This seem rather limiting... Suppose I want a trigger that after insert,
> returns the currval(sequence) of the newly inserted row automatically
> without having to run another query ???
Because you can't capture the return value of a trigger. The trigger is
returning the new/altered/deleted row.
If you want a function to return a value, don't use a trigger.
--
-Josh Berkus
Aglio Database Solutions
San Francisco
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-sql@postgresql.org
Cc: josh@agliodbs.com, GPatnude@adelphia.net, pgsql-general@postgresql.org
Subject: Re: [SQL] Why must the function that a trigger calls return "opaque" ???
In-Reply-To: <200208291105.25725.josh@agliodbs.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