SQL Server track Tables usage

techresearch7777777 1,981 Reputation points
2022-12-01T20:49:15.777+00:00

Hello, I need to track/get some metrics for some specific Tables of what queries (Select, Insert, Update, Delete), how many times, and who accessed them say for a period of 3 months.

Would SQL Audit be the most efficient/least impact/risks to do this and if yes can someone point me to step by step directions on how to set it up...or if something different recommended I'm open to.

Thanks in advance.

SQL Server | Other
0 comments No comments
{count} votes

Answer accepted by question author
  1. PandaPan-MSFT 1,931 Reputation points
    2022-12-02T02:58:03.387+00:00

    Hi @techresearch7777777 ,

    I need to track/get some metrics for some specific Tables of what queries (Select, Insert, Update, Delete),

    You can check this link : https://learn.microsoft.com/en-us/sql/t-sql/statements/create-database-audit-specification-transact-sql?redirectedfrom=MSDN&view=sql-server-ver16

    automatically upon SQL Server start on like when the Server gets rebooted?

    I tested on my own I think that it is default to start automatically.
    266423-image.png


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment"

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. techresearch7777777 1,981 Reputation points
    2022-12-02T00:48:06.803+00:00

    I created a SQL Audit, how can I have this turned on automatically upon SQL Server start on like when the Server gets rebooted?

    Thanks in advance.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.