Subject | Re: foreign keys ans slow insert |
---|---|
Author | Svein Erling Tysvær |
Post date | 2004-09-30T10:09:23Z |
--- In firebird-support@yahoogroups.com, "Bamsemums" wrote:
today to know that a future implementation of Firebird one day may fix
it! Today, updating indexes with lots of records is time consuming and
we end up writing something like
CHECK (VALUE IS NULL OR EXISTS(SELECT * FROM VALUETYPES WHERE
VALIDVALUE = :VALUE)); //Assuming this to be legal.
rather than use foreign keys for tables with lots of duplicates
whenever the table with the legal values is not subject to frequent
updating. Though I didn't think this affected inserts at all, just
updates and deletes.
Set
> > CHECK (VALUE IS NULL OR VALUE IN('CASH', 'CHEQUE','CREDIT'));I agree with Martijn, but the problem is that it doesn't help German
>
> IMO, this really is a FB implementation problem.
today to know that a future implementation of Firebird one day may fix
it! Today, updating indexes with lots of records is time consuming and
we end up writing something like
CHECK (VALUE IS NULL OR EXISTS(SELECT * FROM VALUETYPES WHERE
VALIDVALUE = :VALUE)); //Assuming this to be legal.
rather than use foreign keys for tables with lots of duplicates
whenever the table with the legal values is not subject to frequent
updating. Though I didn't think this affected inserts at all, just
updates and deletes.
Set