Skip site navigation (1) Skip section navigation (2)

Trigger Question

From: Terry Lee Tucker <terry(at)esc1(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Trigger Question
Date: 2004-01-13 21:07:35
Message-ID: (view raw or whole thread)
Lists: pgsql-generalpgsql-novice

I have a simple question. I have been looking at the HTML docs for Postgres 
version: PostgreSQL 7.2.3-RH on i686-pc-linux-gnu, compiled by GCC 2.96. I 
need to know if it is necessary to RETURN NULL from a trigger function after 
raising an exception with RAISE EXCEPTION. We are doing many different data 
validations in a "BEFORE UPDATE OR INSERT" trigger and we have been raising 
an exception with an error string such that the error comes back to the 
X-Windows applicaton. I read that returning NULL prevents other triggers from 
fireing but doesn't RAISE EXCEPTION abort the tranaction and cause all 
processing to stop?

Thanks in advance for your help...
"The world we have created is a product of our thinking. It cannot be
 changed without changing our thinking."

 --Albert Einstein

 Work: 1-336-372-6812
 Cell: 1-336-363-4719
email: terry(at)esc1(dot)com


pgsql-novice by date

Next:From: Lduren02Date: 2004-01-13 21:47:27
Subject: installing postgre
Previous:From: Devrim GUNDUZDate: 2004-01-13 14:42:02
Subject: Re: PostgreSQL booting automaticaly

pgsql-general by date

Next:From: netadminDate: 2004-01-13 21:13:28
Subject: Re: Best practice? Web application: single PostgreSQL
Previous:From: Bruno Wolff IIIDate: 2004-01-13 21:07:12
Subject: Re: Error since powerouttage

Privacy Policy | About PostgreSQL
Copyright © 1996-2015 The PostgreSQL Global Development Group