Re: Prevent double entries ... no simple unique index - Mailing list pgsql-sql

From Rosser Schwarz
Subject Re: Prevent double entries ... no simple unique index
Date
Msg-id CAFnxYwhSjbyCerkWkaWJD61p=T7WYVTP1t9zVaO46Yr0CSE-sg@mail.gmail.com
Whole thread Raw
In response to Prevent double entries ... no simple unique index  (Andreas <maps.on@gmx.net>)
List pgsql-sql
On Wed, Jul 11, 2012 at 12:50 AM, Andreas <maps.on@gmx.net> wrote:

[...]

> I can't simply move rejected events in an archive table and keep a unique
> index on object_id as there are other descriptive tables that reference the
> event_log.id.

Would a multi-column index, unique on (id, state) meet your need?

rls

-- 
:wq


pgsql-sql by date:

Previous
From: Andreas Kretschmer
Date:
Subject: Re: Prevent double entries ... no simple unique index
Next
From: "Marc Mamin"
Date:
Subject: Re: Prevent double entries ... no simple unique index