exam questions

Exam 70-764 All Questions

View all questions & answers for the 70-764 exam

Exam 70-764 topic 1 question 256 discussion

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

You administer a SQL Server 2014 instance.
Users report that the SQL Server has seemed slow today.
A large database was being restored for much of the day, which could be causing issues.
You want to write a query of the system views that will report the following:
✑ Number of users that have a connection to the server
✑ Whether a user's connection is active
✑ Whether any connections are blocked
✑ What queries are being executed
✑ Whether the database restore is still executing and, if it is, what percentage of the restore is complete.
Which system objects should you use in your query to best achieve this task?

  • A. sys.dm_exec_requests, sys.dm_exec_sessions, sys.objects
  • B. sys.dm_exec_sessions, sys.dm_exec_query_stats, sys.dm_exec_query_text,sys.objects
  • C. sys.sysprocesses, sys.dm_exec_query_text, sys.objects
  • D. sys.dm_exec_requests, sys.dm_exec_sessions, sys.dm_exec_query_text
Show Suggested Answer Hide Answer
Suggested Answer: D 🗳️
- sys.dm_exec_requests
Returns information about each request that is executing within SQL Server.
- sys.dm_exec_sessions
Returns one row per authenticated session on SQL Server. sys.dm_exec_sessions is a serverscope view that shows information about all active user connections and internal tasks. This information includes client version, client program name, client login time, login user, current session setting, and more.
- sys.dm_exec_query_text
Returns the text of the SQL batch that is identified by the specified sql_handle.
Incorrect Answers:
- sys.dm_exec_query_stats Returns aggregate performance statistics for cached query plans in SQL Server.
The view contains one row per query statement within the cached plan, and the lifetime of the rows are tied to the plan itself.
- sys.objects
Contains a row for each user-defined, schema-scoped object that is created within a database.

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
nazant
4 years, 7 months ago
And what about "Whether the database restore is still executing and, if it is, what percentage of the restore is complete."? Which DMV gives us this information?
upvoted 1 times
Cococo
4 years, 6 months ago
https://alibaba-cloud.medium.com/sql-server-best-practices-monitoring-backup-and-restore-progress-2ff10a7a43f8
upvoted 1 times
...
...
EgzTst
4 years, 8 months ago
There is no sys.dm_exec_query_text view in SQL2016
upvoted 1 times
Cococo
4 years, 6 months ago
https://docs.microsoft.com/en-us/sql/relational-databases/system-dynamic-management-views/sys-dm-exec-sql-text-transact-sql?view=sql-server-ver15
upvoted 1 times
...
Harvelino
4 years, 4 months ago
Question is about SQL 2014
upvoted 1 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