referential integrity, my friend.

it basically is another layer of protection for dumb mistakes.  it
prevents you from removing a row in a table that is used by another
table.  it helps prevent orphan records.

tw

On 6/2/05, Matthew Small <[EMAIL PROTECTED]> wrote:
> For the past 8 years I've been working with SQL, I've never really
> understood how to use the relational diagrams that use primary and foreign
> keys.  I just recently found the diagram tool in SQL and I like it for
> laying out my new databases.  However, even though I understand the
> concepts, I don't really see the use of connecting the tables together in
> these diagrams, of declaring the foreign and primary keys in these things.
> In my programming, I know which tables are related to other tables, but why
> is it good to tell the db what these relationships are?
> 
> 
> 
> Thanks,
> 
> 
> 
> Matthew Small
> 
> Web Developer
> 
> American City Business Journals
> 
> 704-973-1045
> 
> [EMAIL PROTECTED]
> 
> 
> 
> 
> 
> 
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:5:159467
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/5
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:5
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.5
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to