SELECT
CASE sysobjects.xtype
WHEN 'V' THEN 'VIEW'
WHEN 'U' THEN 'USER TABLE'
WHEN 'S' THEN 'SYSTEM TABLE'
ELSE sysobjects.xtype END AS OBJ_TYPE,
sysobjects.name OBJ_NAME
FROM syscolumns
LEFT JOIN sysobjects ON sysobjects.id = syscolumns.id
WHERE syscolumns.name = 'yourcolumnname'
ORDER BY 1,2
Happy scripting!
Did this help you? If so, please leave a comment!