Subject Re: [ib-support] About enforcing uniqueness with triggers
Author Matteo Giacomazzi
Hi Raul,

Wednesday, July 03, 2002, you wrote:

RC> I keep seeing a common missconception apearing, from time to time,
RC> in this kind of forums. It is that one could enforce uniqueness of
RC> one or more fields in a table with triggers instead of a unique
RC> key.

Generally, I would say that you have to use triggers when the things
you want to verify is local to the record you're dealing with.
If you want to verify something about the full set of data present in
your DB, you should take into account to use something different...

Anyway, if you have to perform an INSERT into a trigger, I guess you
should take into account the case that it could raise an exception
(and that you should handle it in some way).

My 2 cents (if what I said is correct, of course! ;))

Kind regards,

ICQ# 24075529