Re: Database Design Best Practice help
Date: Thu, 31 Jan 2013 17:46:21 -0500
Message-ID: <510AF43D.5020608_at_comcast.net>
Elementary explanation...
What you're showing there are library tables. (specie, movement,diseaselib)differentiatedby thedescriptionof the LIBRARY, which is one reason youdon’twant this in one table. At the least you would add a unique primary key system generated IDcolumn. That would become the foreignkey for the row/value in other tables and for joined queries
i.e.
SPECIE_LIB
SYS_GEN_ID CODE DESCRIPTION/SPECIE
8735688 0801 Poultry
You would then reference either the CODE or the DESCRIPTION/SPECIE as the SYS_GEN_ID as foreignkeys in other tables orqueries. This will also provide functionality tochangethecode or description/specie throughout the database as it always referencesthelibrary table SYS_GEN_ID for look up (not the actual values). The SYS_GEN_ID does NOT ever change.
Just my 2cts
-- http://www.freelists.org/webpage/oracle-l
--
"Oracle error messages being what they are, do not highlight the correct cause of fault, but will identify some other error located close to where the real fault lies."
-- http://www.freelists.org/webpage/oracle-lReceived on Thu Jan 31 2013 - 23:46:21 CET