0

difference between candidate key and foreign key in sql ?

I am not able

22nd Jul 2017, 5:12 AM
Deepak Kumar
Deepak Kumar - avatar
1 Answer
0
create table persons ( personid int not null, name varchar (30), primary key (personid) ) create table orders ( orderid int not null, name varchar (30), personid int not null, primary key (orderid), foreign key (personid) references persons(personid) )
25th Jul 2017, 5:14 AM
Claudiu Stefan Haidu
Claudiu Stefan Haidu - avatar