SQL – Foreign Key and its use Database
In this article you will learn about- What is foreign Key? A foreign key can be defined in either a CREATE TABLE statement or an ALTER TABLE statement. Using a CREATE TABLE statement Syntax: The syntax for creating a foreign key using a CREATE TABLE statement is: Example: Parent Table – STOCK Using an ALTER…