Using XML Schemas
XML programming in SMO is limited to providing XML data types, XML namespaces, and simple indexing on XML data type columns.
Microsoft SQL Server provides native storage for XML document instances. XML schemas let you define complex XML data types, which can be used to validate XML documents to ensure data integrity. The XML schema is defined in the XmlSchemaCollection object.