Monitor changes to table column names | SQL Server Performance Forums

SQL Server Performance Forum – Threads Archive

Monitor changes to table column names

New to the scene so watz up to the house!! My question?
I want to know imediatly when someone changes a column name or data type of a table.
DDL triggers will tell alert me on data type changes but not column name changes.
I can certainly create my own trigger but was wondering if something already exist and I just havent come accross it yet. Just trying to avoid re-inventing the wheel. Thanks
I believe DDL triggers will fire only for ALTER/CREATE/DROP statement but not when sp_rename procedure executes… sp_rename use DBCC RENAMECOLUMN procedure to rename the column… I never come across the trigger script for column rename…
If you write or find on the web please share with the group…
MohammedU.
Moderator
SQL-Server-Performance.com
I’ll take a stap when I get some time.
FYI: stumbled across sp_foreachtabl & sp_foreachdb as possible solutions as well.

I believe you can’t run sp_foreachtabl & sp_foreachdb procedures at the same time…it uses global cursor…
MohammedU.
Moderator
SQL-Server-Performance.com
Be aware there are undocumented stored procedures and it might not have affect on all the tables, within SQL 2005. Satya SKJ
Microsoft SQL Server MVP
Writer, Contributing Editor & Moderator
http://www.SQL-Server-Performance.Com
This posting is provided AS IS with no rights for the sake of knowledge sharing. The greatest discovery of my generation is that a human being can alter his life by altering his attitudes of mind.
]]>