Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

how to add foreign key constraint in sql

ALTER TABLE 'table_name'
ADD CONSTRAINT 'constraint_name' FOREIGN KEY 'foreign_key' REFERENCES 'column_name'('primary_key');
 
PREVIOUS NEXT
Tagged: #add #foreign #key #constraint #sql
ADD COMMENT
Topic
Name
9+6 =