Explain foreign key in sql?



Explain foreign key in sql?..

Answer / Kundan Kumar Vats

A foreign key is a field or set of fields in one table that refers to the primary key of another table. It establishes a link, or relationship, between two tables, enabling data from both tables to be related. A foreign key helps maintain data integrity by ensuring referential consistency, preventing orphaned records and other errors.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More SQL PLSQL Interview Questions

How do I turn a list into a table?

1 Answers  


What is the difference between sql/pl-sql/embeded sql?

3 Answers  


What are the sql aggregate functions?

1 Answers  


How do you define a foreign key?

1 Answers  


Is merge a dml statement?

1 Answers  


What does pragma mean?

1 Answers  


What is Temp Table and type of temp table?

1 Answers   HP, SLK,


how a reference cursor works?what all adnvantages are gained with it..specify the situation?

4 Answers   TCS,


What is window clause?

1 Answers   TCS,


what is msql? : Sql dba

1 Answers  


What are the different dml commands in sql?

1 Answers  


What are the constraints available in sql?

1 Answers  


Categories