Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Help on Data Integrity Constraints

Re: Help on Data Integrity Constraints

From: <andrewst_at_onetel.com>
Date: 4 May 2005 02:45:04 -0700
Message-ID: <1115199904.912446.40960@f14g2000cwb.googlegroups.com>


vsatya_at_gmail.com wrote:
> Suppose I have a table "Master" with 3 fields
> Table Name: "Master"
> Columns:
> Type Varchar2(10)
> Code Varchar2(5)
> Desc Varchar2(20)
>
> Combination of Type & Code is the Primary key.
>
> Let's say this table acts like master/setup data to different
constants
> that will be used in the system.
>
> Sample Data:
>
> Type Code Desc
> --------------------------------------
> AISTATUS A Active
> AISTATUS I InActive
> ROLE MGR Manager
> ROLE DIR Director
> ROLE SRMGR Senior Manager
> SEX M Male
> SEX F Female
> .....
> .....

This is the infamous "One True Lookup Table" (OTLT), which is a common lousy approach to database design along with its friend the Entity-Attribute-Value table (EAV):

http://tonyandrews.blogspot.com/2004/10/otlt-and-eav-two-big-design-mistakes.html Received on Wed May 04 2005 - 04:45:04 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US