Chapter 7. XML Data
SQL Server 2005 provides extensive support for XML data storage and processing. You can store XML documents and fragments natively as columns and T-SQL variables of the new xml data type. xml data type columns can be indexed, typed according to an XML schema, and manipulated using XQuery and XML Data Manipulation Language (DML).
A relational model is particularly suited to data that is highly structured with a well-known, well-defined schema. XML data, on the other hand, is suitable to handling data with a flexible, evolving, or unknown structure. XML is also well suited to storing data that represents a containment hierarchy.
Some reasons to store data as XML include the following:
In addition to natively storing XML data, SQL Server 2005 lets you map relational data to XML data using XQuery extension functions and map XML data to relational data using the FOR XML clause.
SQL Server 2005 includes SQLXML 4.0. This extends and enhances the client-side XML functionality introduced in SQLXML 3.0, which shipped as a web release after the release of SQL Server 2000.