Re: Undoing a sequence increment with autonumbering
From: Frank <fvanbortel_at_netscape.net>
Date: Wed, 05 Feb 2003 21:27:18 +0100
Message-ID: <3E4173A6.2010601_at_netscape.net>
Date: Wed, 05 Feb 2003 21:27:18 +0100
Message-ID: <3E4173A6.2010601_at_netscape.net>
In case of a rollback, the update on code_table is rolled back,
too.
To make things idiot proof, do a select for update, thus locking
the record (in case of a single code table per table this would
effectively lock the table...) for other, simultaneous transactions.
Not as effective as a sequence, but pretty standard when you are required to deliver contiguous sequentially numbered records.
Frank Received on Wed Feb 05 2003 - 21:27:18 CET