How to capture which users are running which queries against which object

  • I am able to capture which users is executing which query using extended events but how do I identify/capture  which object (object id/name)  the query is running against?

  • Do you have any monitoring tools?

  • no sir

  • You have to look at the T-SQL within the extended event. There isn't a tool out there that captures metrics by table. Any given query or batch can be hitting multiple tables, multiple times. To see this information by table, you'll have to break it down yourself.

    What is the goal of identifying the tables? What are you hoping to achieve?

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply