exam questions

Exam 70-761 All Questions

View all questions & answers for the 70-761 exam

Exam 70-761 topic 1 question 120 discussion

Actual exam question from Microsoft's 70-761
Question #: 120
Topic #: 1
[All 70-761 Questions]

You need to create a database object that meets the following requirements:
✑ accepts a product identifies as input
calculates the total quantity of a specific product, including quantity on hand and quantity on order

✑ caches and reuses execution plan
✑ returns a value
✑ can be called from within a SELECT statement
✑ can be used in a JOIN clause
What should you create?

  • A. a temporary table that has a columnstore index
  • B. a user-defined table-valued function
  • C. a memory-optimized table that has updated statistics
  • D. a natively-complied stored procedure that has an OUTPUT parameter
Show Suggested Answer Hide Answer
Suggested Answer: B 🗳️
A table-valued user-defined function can also replace stored procedures that return a single result set. The table returned by a user-defined function can be referenced in the FROM clause of a Transact-SQL statement, but stored procedures that return result sets cannot.
References:
https://technet.microsoft.com/en-us/library/ms191165(v=sql.105).aspx

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
Deimy
Highly Voted 4 years, 8 months ago
seems more like "a user-defined scalar function"
upvoted 7 times
Andy7622
4 years, 4 months ago
But how would you use scalar function in joins? You can't join a table with a single value.
upvoted 2 times
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago