Foreign keys , Database Management System

Assignment Help:

Foreign Keys and NULL

Let us take the relation:                

DEPT

DEPT ID

DNAME

BUDGET

D1

Marketing

10M

D2

Development

12M

D3

Research

5M

 

EMP

EMP

ID

ENAME

DEPT

ID

SALARY

E1

Rahul

D1

40K

E2

Aparna

D1

42K

E3

Ankit

D2

30K

E4

Sangeeta

 

35K

Assume that Sangeeta is not assigned any section. In the EMP tuple corresponding to Sangeeta, thus, there is no genuine section number that can serve as the appropriate value for the DEPTID foreign key. Thus, one cannot verify BUDGET and DNAME for Sangeeta's department as those values are NULL. This may be actual circumstances where the person has newly joined and is undergoing training and will be allocated to a department only on finishing of the training. Thus, NULL in foreign key values might not be a logical error.

Thus, the foreign key definition may be redefined to conatin NULL as an acceptable value in the foreign key for which there is no require to find a matching tuple.

Is there any other constraint that may be applicable on the attribute values of the entities?

Yes, these constraints are mostly linked to the domain and termed as the domain constraints.


Related Discussions:- Foreign keys

Windows 8 Administrative Tools, Which two tools are used to administer user...

Which two tools are used to administer users for Active Directory?

What is completeness constraint on generalization, What is completeness con...

What is completeness constraint on generalization? Define the variation between total and partial design constraint. Give an example each.       Ans: Completeness Constraints

Failure controlling methods, Failure Controlling Methods: Failures can be h...

Failure Controlling Methods: Failures can be handled using different recovery methods that are talk about later in the unit. But the first question is doing we really require recov

Types of attributes, Attributes attached to an entity can be of various typ...

Attributes attached to an entity can be of various types. Simple The attribute that cannot be further separated into smaller parts and shows the basic meaning is known as a

What are the causes of bucket overflow in a hash file, What are the causes ...

What are the causes of bucket overflow in a hash file organization? What can be done to reduce the occurrence of bucket overflow? When a record is inserted, the bucket to that

What are the various forms of data transparency, What are the various forms...

What are the various forms of data transparency? a) fragmentation transparency b) replication transparency c) location transparency

What are composite objects, What are composite objects? Objects that ha...

What are composite objects? Objects that have other objects are known as complex objects or composite objects.

Describe the different raid levels, Describe the different RAID levels.  Di...

Describe the different RAID levels.  Discuss the choices of the different RAID levels for different applications.          Ans:   There are several combinations of these approa

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd