Monitoring access to a Database

  • Hi,

    what possibilities there are to monitors access to a database. It is to be recorded, which user or client accesses it. And not on all tables, only tables to a certain scheme.

    Background: The database will soon be switched off...

    Thanks and

    Regards

    Nicole 😉

  • On a 2008 system, I'd use trace events. You can capture rpc_completed and sql_batch_completed calls which will show you what's being accessed. Unfortunately, filtering in trace events doesn't work that well. You can do it, but the methodology of trace events means that it captures the event first, then filters, which means the negative sides of auditing are not mitigated by the filter. It's still the best way to go though.

    If we weren't in 2008, I'd recommend extended events, but, if I'm remembering correctly, sql_batch_completed is not in 2008, limiting the capability of extended events there.

    "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 2 posts - 1 through 1 (of 1 total)

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