From: Erik Jones <erik@myemma.com>
To: Richard Broersma Jr <rabroersma@yahoo.com>
Cc: General Postgresql List <pgsql-sql@postgresql.org>
Subject: Re: Alternative to Select in table check constraint
Date: Sat, 01 Jul 2006 07:54:04 -0500
Message-ID: <44A6706C.6000503@myemma.com> (raw)
In-Reply-To: <20060701014108.79890.qmail@web31811.mail.mud.yahoo.com>
References: <20060701014108.79890.qmail@web31811.mail.mud.yahoo.com>
Richard Broersma Jr wrote:
> But now that I think about it, using the authors suggestion (if it actually worked), how would
> would it be possible to change the active status from one badge to another?
>
Well, the check constraint as you wrote it requires that there always be
a badge listed as active for each employee. If you changed
the contstraint to: CHECK ( 2 > .....) then you'd be able to unset the
active status and then set a new one to active.
--
erik jones <erik@myemma.com>
software development
emma(r)
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: erik@myemma.com, rabroersma@yahoo.com
Subject: Re: Alternative to Select in table check constraint
In-Reply-To: <44A6706C.6000503@myemma.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