Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 Audit options

Author  Topic 

ldygahan
Starting Member

3 Posts

Posted - 2010-08-14 : 10:14:10
Yes, I know I can achieve that very easily through triggers... however, I was wondering whether it is possible to catch outliers only for a certain column in a table through audit.

For example. Whenever someone updates (or a row gets inserted) with a value above 1000, let's say, the info about that goes into the audit table.

I researched CREATE DATABASE AUDIT SPECIFICATION statement and so far I haven't found a way to add the condition to the audit.

for example...


ADD (INSERT , UPDATE
ON issue_table /* can I here add column and a condition, somehow? */
BY PUBLIC)

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2010-08-14 : 13:22:32
You would use a DML trigger for this. Why don't you want to use it?

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog
Go to Top of Page
   

- Advertisement -