You have a database that contains the tables shown in the exhibit. (Refer to the Exhibit.)
You need to create a view named uv_CustomerFullNameto meet the following requirements:
The code must NOT include object delimiters.
The view must be created in the Sales schema.
Columns must only be referenced by using one-part names.
The view must return the first name and the last name of all customers.
The view must prevent the underlying structure of the customer table from being changed.
The view must be able to resolve all referenced objects, regardless of the user’s default schema.
Which code segment should you use?
To answer, type the correct code in the answer area.
A.
Explanation:
CREATE VIEW Sales.uv_CustomerFullName
WITH SCHEMABINDING
AS
SELECT FirstName, LastName
FROM Sales.Customers
Reference: http://msdn.microsoft.com/en-us/library/ms187956.aspx
I’d assume it has to be “dbo.Customers” instead of “Sales.Customers” because in the exhibit there is only said “Customers” and not “Customers (Sales)” as it would be if the Customers table resided in the Sales schema.
0
0
The view must be created in the Sales schema.
0
0
Create View Sales.uv_CustomerFullName
WITH SCHEMA BINDING
Select Firstname,lastname from
Sales.Customers
0
0