WGU D427 DATA MANAGEMENT
APPLICATIONS FINAL PAPER UPDATED
QUESTIONS VERIFIED COMPLETE
ANSWERS 100 PERCENT CORRECT
◉ CREATE TABLE Department (
Code INT UNSIGNED,
ManagerID INT UNSIGNED,
PRIMARY KEY (Code),
FOREIGN KEY (ManagerID) REFERENCES Employee(ID)
);
This would make the ManagerID be a foreign key of the ID column
on the employee table.
Answer: To set the foreign key, you would include it in the _______
__________ statement.
The syntax is:
◉ A signed number may be negative.
, An unsigned number cannot be negative.
Answer: With integers, remember the difference between signed
and unsigned numbers!
◉ RESTRICT
CASCADE
SET NULL
SET DEFAULT
On a FOREIGN KEY for example:
CREATE TABLE Department (
Code INT UNSIGNED,
ManagerID INT UNSIGNED,
PRIMARY KEY (Code),
FOREIGN KEY (ManagerID) REFERENCES Employee(ID),
ON DELETE CASCADE,
ON UPDATE SET NULL
);
Answer: What are the four referential integrity constraints that can
be used?
APPLICATIONS FINAL PAPER UPDATED
QUESTIONS VERIFIED COMPLETE
ANSWERS 100 PERCENT CORRECT
◉ CREATE TABLE Department (
Code INT UNSIGNED,
ManagerID INT UNSIGNED,
PRIMARY KEY (Code),
FOREIGN KEY (ManagerID) REFERENCES Employee(ID)
);
This would make the ManagerID be a foreign key of the ID column
on the employee table.
Answer: To set the foreign key, you would include it in the _______
__________ statement.
The syntax is:
◉ A signed number may be negative.
, An unsigned number cannot be negative.
Answer: With integers, remember the difference between signed
and unsigned numbers!
◉ RESTRICT
CASCADE
SET NULL
SET DEFAULT
On a FOREIGN KEY for example:
CREATE TABLE Department (
Code INT UNSIGNED,
ManagerID INT UNSIGNED,
PRIMARY KEY (Code),
FOREIGN KEY (ManagerID) REFERENCES Employee(ID),
ON DELETE CASCADE,
ON UPDATE SET NULL
);
Answer: What are the four referential integrity constraints that can
be used?