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

Re: Triggers per transaction, workaround? prospects?

From: Gregory Wood <gwood(at)ewebengine(dot)com>
To: "Karl O(dot) Pinc" <kop(at)meme(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Triggers per transaction, workaround? prospects?
Date: 2004-02-29 14:11:20
Message-ID: 4041F308.9030701@ewebengine.com (view raw or flat)
Thread:
Lists: pgsql-general
Karl O. Pinc wrote:
> a per-person counter, which must not contain any 'gaps'.  I can do this
> so long as nobody every makes any mistakes
> in sequencing, but once the sequence numbers are in place
> there's no way to re-order the rows in a sequence
> (the rows belonging to one person) without deleting
> and re-creating all the rows with sequence numbers

I can't answer your particular question, but you can always put an ON 
UPDATE CASCADE into your foreign keys... then if you *shudder* had to 
change those values, it should cascade out through all the attached rows 
in other tables.

Greg

In response to

Responses

pgsql-general by date

Next:From: Geoffrey KinnelDate: 2004-02-29 15:06:13
Subject: Re: Where are the backend/commands?
Previous:From: Shachar ShemeshDate: 2004-02-29 06:47:42
Subject: Re: SERIAL type - auto-increment grouped by other field

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