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

Home -> Community -> Usenet -> comp.databases.theory -> Same field as a primary and foriegn key

Same field as a primary and foriegn key

From: Ryan <ryanwhtang_at_gmail.com>
Date: 9 Jan 2005 23:28:19 -0800
Message-ID: <1105342099.536055.103780@c13g2000cwb.googlegroups.com>


Hi,

Let say there are 2 tables for an application, one stores the customer data, CUS_DATA, and another one store the customer activities in the application, CUS_LOG. Both tables have the field CUS_ID as the primary key.

Should I enforce referential integrity between the 2 tables, such that the CUS_ID field in CUS_LOG is a primary key and as well as a foreign key that relates to the primary key CUS_ID in CUS_DATA? Thank you.

Ryan Received on Mon Jan 10 2005 - 01:28:19 CST

Original text of this message

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