SELECT name, SCHEMA_NAME(schema_id) AS schema_name, type_desc , type
FROM sys.objects
WHERE parent_object_id = (OBJECT_ID(‘dbo.tblXXXX’))
AND type IN (‘C’,’F’,’PK’,’D’, ‘UQ’)
order by name;
GO
SELECT name, SCHEMA_NAME(schema_id) AS schema_name, type_desc , type
FROM sys.objects
WHERE parent_object_id = (OBJECT_ID(‘dbo.tblXXXX’))
AND type IN (‘C’,’F’,’PK’,’D’, ‘UQ’)
order by name;
GO
Comments