SQL Audit

Technical Article

Generic trigger for maintaining the Audit Log

  • Script

This trigger will work even if you don't have the primary key on any table. Mechanism to configure the primary key in config table has been provided. This can be very helpful to solve the system audit requirements without much efforts.

Disclaimer : Audit Log trigger has performance overhead. It’s meant for table which is not frequently updated, deleted or inserted. Please take precaution when creating the trigger on the table having too many columns.

(3)

You rated this post out of 5. Change rating

2019-10-15 (first published: )

3,087 reads

Blogs

Tech Conferences and Expanding Your View

By

Tech conferences aren't just for networking and learning how to address a problem you're...

Managing subscribers, creating newsletters

By

When I created the website on WordPress, I was expecting all the features I...

Finding the Last Last Name in SQL: #SQLNewBlogger

By

I wrote a piece on the new SUBSTRING in SQL Server 2025 and got...

Read the latest Blogs

Forums

Getting the Schema for Tables

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Getting the Schema for Tables

An Unexciting Exciting Release

By Steve Jones - SSC Editor

Comments posted to this topic are about the item An Unexciting Exciting Release

UNLOGGED Tables in PostgreSQL: When Speed Matters More Than Durability

By Chandan Shukla

Comments posted to this topic are about the item UNLOGGED Tables in PostgreSQL: When...

Visit the forum

Question of the Day

Getting the Schema for Tables

What happens when I run this on SQL Server 2022 in the AdventureWorks2022 database?

SELECT OBJECT_DEFINITION (OBJECT_ID(N'Person.Person')) AS [Object Definition]; 
GO 

See possible answers