5,268 views

1 Answer

0 votes
0 votes

Foreign Key

The key of a table which acts as a primary key of some another table.

The recursive foreign key is the key which refers back to the same table i.e. the foreign key is in the same table. So Parent and child table is the same.

For example :

Let's have a table Employee having to fields empID and managedbyempID, this both fields contain the employee id's(Both are employees)  from the same table. One act as a primary key and another one will act as a recursive foreign key.  

Related questions

3 votes
3 votes
2 answers
1
Hira Thakur asked Nov 3, 2016
1,502 views
What is on delete no action,on delete cascade, on delete set null action??explain through some eg??
0 votes
0 votes
1 answer
4
Bhagirathi asked Feb 3, 2016
455 views
what is the advantage of keeping the Foreign Key null as we know if we make the Foreign Key null we cant reference it again so thats a disadvantage ......so there must be...