Search a specific column name in all tables SQL Server

SELECT name FROM sysobjects WHERE id IN ( SELECT id FROM syscolumns WHERE name = ‘COLUMN_NAME’ );

 

SELECT name FROM sysobjects WHERE id IN ( SELECT id FROM syscolumns WHERE name  like  ‘%COLUMN_NAME%’ );

Advertisements