On Mon, Jul 08, 2002 at 17:49:56 +0200,
  Joachim Trinkwitz <[EMAIL PROTECTED]> wrote:
> 
> Now I want to allow a user with id 123 only to insert a row in T if he
> doesn't choose values from L with same 'art' and 'semester' values --
> in the examples user 123 has already chosen a kvvnr from semester
> 2002ws in category 'art', so he shouldn't be allowed to insert the
> values of the second row in table L.

In the database you enforce this using a unique index.
The application needs to be able to handle failures when you try to
insert a duplicate key.

If you can't afford to have a transaction fail part way through, then
anything that writes that table should do a table lock at the start
of the transaction.



---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Reply via email to