1.

Which keyword is used to specify the foreign key after the table is created?(a) SETUP(b) SET(c) ALTER TABLE(d) SPECIFYI have been asked this question in an interview for internship.My question is taken from Foreign Keys and Referential Integrity in portion Using SQL to Manage Data of MySQL

Answer»

The correct ANSWER is (c) ALTER TABLE

Easiest explanation: When the table has ALREADY been created but the foreign KEY has not been set of foreign key CONSTRAINTS are not specified, the ‘ALTER TABLE – ADD FOREIGN KEY’ clause is USED.



Discussion

No Comment Found

Related InterviewSolutions