Re: When to use check constraints and when to use small tables?
- From: plinehan@xxxxxxxxx
- Date: 25 May 2006 00:15:25 -0700
If you think the # of values is going to change, or the values are
going to alter, and you don't want to have to change the app or the
check constraints: put them in a table.
Well, what I was asking was when it is appropriate to
change the app by modifying check constraints on
a table - is the rule about no DDL in an application
an *_ABSOLUTE_* one, and if not, what are the
circumstances under which it should be allowed?
If the number of values is more than 3: always put them in a table.
You might forget a state or miscount them.
Ah, I see. This is a perspective I had forgotten about
when framing my original post - I forgot to think about
those application programmers for example who will
have to write reports on the data in the app - it's true
enough that anything beyond two or three is probably
too much - I mean gender is OK but what about title?
The part of my post which hasn't been addressed is
what sort of indexes to put on the Person table - i.e.
a bitmap index if it's only two values - what about higher
numbers - what's the rule of thumb for the cardinality
of bitmap indexes?
Also, the construction of these "minor" tables - should
they be indexed, and if so, what sort of index should be
used - and if there are differences, why?
Paul...
.
- Follow-Ups:
- Re: When to use check constraints and when to use small tables?
- From: Brian Peasland
- Re: When to use check constraints and when to use small tables?
- From: Jaap W. van Dijk
- Re: When to use check constraints and when to use small tables?
- References:
- When to use check constraints and when to use small tables?
- From: Paul
- Re: When to use check constraints and when to use small tables?
- From: Sybrand Bakker
- When to use check constraints and when to use small tables?
- Prev by Date: Re: QUESTION: raise_application_error results in ORA-00604...?
- Next by Date: Re: When to use check constraints and when to use small tables?
- Previous by thread: Re: When to use check constraints and when to use small tables?
- Next by thread: Re: When to use check constraints and when to use small tables?
- Index(es):
Relevant Pages
|