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 2005 Forums
 Transact-SQL (2005)
 Backtrace changes to data row of table

Author  Topic 

Taetsu
Starting Member

1 Post

Posted - 2011-05-30 : 09:46:37
I have a table - Messages, every time i add a new data row to the table, it gets removed in a few seconds time.

I want to know who did changes/remove of this table row but i have no idea how to trace it.

I have hundreds of stored procedures to look at if i have to trace it 1 by 1. I looked at the schedule job, nothing suspicious there. What else could be affecting the table rows?

Please enlighten me on this.. Thanks!

lappin
Posting Yak Master

182 Posts

Posted - 2011-06-02 : 11:06:16
You could look at the default trace running already:
http://stackoverflow.com/questions/1043971/determine-which-user-deleted-a-sql-server-database

If not either set up a trigger for delete on the table, or run a trace of your own.

On having to check individual stored procedures, there is a free tool "SQL Search" which lets you search your databases e.g. for "messages" and it would show all procedures etc which reference it (but not jobs)
http://www.red-gate.com/products/sql-development/sql-search/?utm_source=google&utm_medium=cpc&utm_content=brand_aware&utm_campaign=sqlsearch&gclid=CL257bO_l6kCFQoa4QodxRsiuA
Go to Top of Page
   

- Advertisement -