Quantcast
Viewing latest article 3
Browse Latest Browse All 7

SQLXML : How to List Schema Elements and Attributes

1: SELECT 2: sys.xml_schema_collections.xml_collection_id AS CollectionID, 3: sys.xml_schema_collections.name AS SchemaName, 4: sys.xml_schema_elements.name AS ElementName, 5: sys.xml_schema_attributes.name AS AttributeName 6: FROM 7: sys.xml_schema_collections 8: INNER JOIN sys.xml_schema_attributes 9: ON sys.xml_schema_collections.xml_collection_id = sys.xml_schema_attributes.xml_collection_id 10: INNER JOIN sys.xml_schema_elements 11: ON sys.xml_schema_collections.xml_collection_id = sys.xml_schema_elements.xml_collection_id 12: WHERE 13: sys.xml_schema_collections.name NOT LIKE 'sys' Sample Result:

Viewing latest article 3
Browse Latest Browse All 7

Trending Articles