Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.
Location Chicago IL, USA

Microsoft 70-461 Exam Actual Questions

The questions for 70-461 were last updated at Feb. 26, 2021.
  • Viewing page 1 out of 53 pages.
  • Viewing questions 1-5 out of 265 questions

Topic 1 - Single Topic

Question #1 Topic 1

You develop a Microsoft SQL Server database that supports an application. The application contains a table that has the following definition:

CREATE TABLE Inventory -
(ItemID int NOT NULL PRIMARY KEY,
ItemsInStore int NOT NULL,
ItemsInWarehouse int NOT NULL)
You need to create a computed column that returns the sum total of the ItemsInStore and ItemsInWarehouse values for each row.
Which Transact-SQL statement should you use?

  • A. ALTER TABLE Inventory ADD TotalItems AS ItemsInStore + ItemsInWarehouse
  • B. ALTER TABLE Inventory ADD ItemsInStore - ItemsInWarehouse = TotalItemss
  • C. ALTER TABLEInventory ADD TotalItems = ItemsInStore + ItemsInWarehouse
  • D. ALTER TABLE Inventory ADD TotalItems AS SUM(ItemsInStore, ItemsInWarehouse);
Reveal Solution Hide Solution   Discussion   1

Correct Answer: A
Reference:
http://technet.microsoft.com/en-us/library/ms190273.aspx

Question #2 Topic 1

You develop a Microsoft SQL Server database. You create a view from the Orders and OrderDetails tables by using the following definition.

You need to improve the performance of the view by persisting data to disk. What should you do?

  • A. Create anINSTEAD OFtrigger on the view.
  • B. Create anAFTERtrigger on the view.
  • C. Modify the view to use theWITH VIEW_METADATAclause.
  • D. Create a clustered index on the view.
Reveal Solution Hide Solution   Discussion  

Correct Answer: D
Reference:
http://msdn.microsoft.com/en-us/library/ms188783.aspx

Question #3 Topic 1

Note: This question is part of a series of questions that use the same set of answer choices. An answer choice may be correct for more than one question in the series.
You develop a database for a travel application. You need to design tables and other database objects.
You create the Airline_Schedules table.
You need to store the departure and arrival dates and times of flights along with time zone information.
What should you do?

  • A. Use the CAST function.
  • B. Use the DATE data type.
  • C. Use the FORMAT function.
  • D. Use an appropriate collation.
  • E. Use a user-defined table type.
  • F. Use the VARBINARY data type.
  • G. Use the DATETIME data type.
  • H. Use the DATETIME2 data type.
  • I. Use the DATETIMEOFFSET data type.
  • J. Use the TODATETIMEOFFSET function.
Reveal Solution Hide Solution   Discussion   4

Correct Answer: I
Reference:
http://msdn.microsoft.com/en-us/library/ff848733.aspx
http://msdn.microsoft.com/en-us/library/bb630289.aspx

Question #4 Topic 1

Note: This question is part of a series of questions that use the same set of answer choices. An answer choice may be correct for more than one question in the series.
You develop a database for a travel application. You need to design tables and other database objects.
You create a stored procedure. You need to supply the stored procedure with multiple event names and their dates as parameters.
What should you do?

  • A. Use the CAST function.
  • B. Use the DATE data type.
  • C. Use the FORMAT function.
  • D. Use an appropriate collation.
  • E. Use a user-defined table type.
  • F. Use the VARBINARY data type.
  • G. Use the DATETIME data type.
  • H. Use the DATETIME2 data type.
  • I. Use the DATETIMEOFFSET data type.
  • J. Use the TODATETIMEOFFSET function.
Reveal Solution Hide Solution   Discussion  

Correct Answer: E

Question #5 Topic 1

SIMULATION -
You have a view that was created by using the following code:

You need to create an inline table-valued function named Sales.fn_OrdersByTerritory, which must meet the following requirements:
✑ Accept the @T integer parameter.
✑ Use one-part names to reference columns.
Filter the query results by SalesTerritoryID.

✑ Return the columns in the same order as the order used in OrdersByTerritoryView.
Part of the correct Transact-SQL has been provided in the answer area below. Enter the Transact-SQL in the answer area that resolves the problem and meets the stated goals or requirements. You can add Transact-SQL within the Transact-SQL segment that has been provided as well as below it.


Reveal Solution Hide Solution   Discussion  

Correct Answer: Please review the explanation part for this answer.
CREATE FUNCTION Sales.fn_OrdersByTerritory (@T int)

RETURNS TABLE -

AS -

RETURN -
(

SELECT -
OrderID,
OrderDate,
SalesTerritoryID,

TotalDue -

FROM Sales.OrdersByTerritory -

WHERE [email protected] -
)


SaveCancel