Exam-Answer

== Trim, Convert and Download YouTube videos at cutyt.com. Free! ==

Home / Microsoft / AZ-303 / Question 110

Prev Question
Next Question

Question 110

You manage an Azure SQL database named DB1.

You want to use the following SQL statements to create three tables in DB1.

Employees table:

CREATE TABLE Employees

(

EmployeeId INT IDENTITY PRIMARY KEY,

FullName NVARCHAR(256) NOT NULL,

BirthDate DATE NOT NULL,

CompanyId INT REFERENCES Companies (CompanyId)

)

Phones table:

CREATE TABLE Phones

(

PhoneNumber INT NOT NULL,

EmployeeId INT REFERENCES Employees (EmployeeId)

)

Companies table:

CREATE TABLE Companies

(

CompanyId INT IDENTITY PRIMARY KEY,

Name NVARCHAR(256) NOT NULL

)

You need to order the SQL statements to create the three tables.

Which statement order should you use to meet the requirements?

Answers



A B C D

Advertisement

Explanation

You should create the tables in the following order: Companies, Employees, and Phones. You should create the Companies table before the Employees table because Employees references Companies using a foreign key. Then, you need to

References

Comments

Load more
Prev Question
Next Question


== Trim, Convert and Download YouTube videos at cutyt.com. Free! ==