Solved

Foreign Key and Not Null

Posted on 2007-04-03
2
172 Views
Last Modified: 2010-03-20
Hi

Just a basic question.  You can't have a foreign key on an item that is not null.  Is this correct?

Greg
0
Comment
Question by:greg_c
2 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 125 total points
ID: 18842173
?
no, that is not correct.

you can have a foreign key pointing from and pointing to a field that is not null.
however, you will need to have the referred value in the "master/lookup" table be present BEFORE you use that value in the child table.
0
 

Author Comment

by:greg_c
ID: 18842235
Thank you
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SQL question - need unique values for one column that is not displayed 2 22
SQL Insert parts by customer 12 34
SQL Error - Query 6 26
SQL Query assistance 16 27
I'm trying, I really am. But I've seen so many wrong approaches involving date(time) boundaries I despair about my inability to explain it. I've seen quite a few recently that define a non-leap year as 364 days, or 366 days and the list goes on. …
PL/SQL can be a very powerful tool for working directly with database tables. Being able to loop will allow you to perform more complex operations, but can be a little tricky to write correctly. This article will provide examples of basic loops alon…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question