COMPUTER SCIENCE AND ENGINEERING
SQL
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
|
The REFERENCES permission is used before a foreign key relationship can specify the object as a target, if no other permissions exist on the referenced object.
|
|
The REFERENCES permission is used after a foreign key relationship specify the object as a target, if no other permissions exist on the referenced object.
|
|
The REFERENCES permission is used before a foreign key relationship can specify the object as a target, if another permissions exist on the referenced object.
|
|
None of the above
|
Detailed explanation-1: -A FOREIGN KEY is a field (or collection of fields) in one table, that refers to the PRIMARY KEY in another table. The table with the foreign key is called the child table, and the table with the primary key is called the referenced or parent table.
Detailed explanation-2: -The REFERENCES permission on a table is needed to create a FOREIGN KEY constraint that references that table. The REFERENCES permission is needed on an object to create a FUNCTION or VIEW with the WITH SCHEMABINDING clause that references that object.
Detailed explanation-3: -A foreign key is a key used to link two tables together. This is sometimes also called as a referencing key. A Foreign Key is a column or a combination of columns whose values match a Primary Key in a different table.
Detailed explanation-4: -A foreign key can reference any field defined as unique. If that unique field is itself defined as a foreign key, it makes no difference.