SELECT OBJECT_NAME(object_id) FROM sys.columns WHERE name = 'foo'
Detta inkluderar dock vyer men kan filtreras ytterligare. Det kan dock vara användbart.
Mer allmänt...
SELECT TABLE_NAME FROM INFORMATION_SCHEMA.COLUMNS WHERE COLUMN_NAME = 'foo'
SELECT OBJECT_NAME(object_id) FROM sys.columns WHERE name = 'foo'
Detta inkluderar dock vyer men kan filtreras ytterligare. Det kan dock vara användbart.
Mer allmänt...
SELECT TABLE_NAME FROM INFORMATION_SCHEMA.COLUMNS WHERE COLUMN_NAME = 'foo'