Subject | Re: [firebird-support] Database Design Issue |
---|---|
Author | Ivan Prenosil |
Post date | 2003-12-05T14:31:06Z |
From: "chee hee"
contain millions of records.
but those solutions can't see behind the "transaction wall", so you have to decide
on which fields you can use it safely in multiuser environment.
E.g. values in lookup table for your "sex" field are good candidates
since they will not change much (there will probably be just 2 values,
but one is not sure what will those genetic engineers invent.
Or perhaps there will be more values, like 69 or so ?)
Ivan
> I have a main table with fields like sex, occupation, model, etc (around 10 of these fields)referencing parent tables respectively. Foreign keys are in placed for these fields. The table will
contain millions of records.
>low selectivity - lots of duplicates.
> Will these foreign keys automatically generate indexes for these fields. If yes, these indexes are
>Right.
> I always heard from the forum that low selectivity will slow down the performance of the table.
>Foreign key constraints can be replaced by Check constraints or triggers,
> How to resolve or maybe I should not enforce the foreign keys.
but those solutions can't see behind the "transaction wall", so you have to decide
on which fields you can use it safely in multiuser environment.
E.g. values in lookup table for your "sex" field are good candidates
since they will not change much (there will probably be just 2 values,
but one is not sure what will those genetic engineers invent.
Or perhaps there will be more values, like 69 or so ?)
Ivan