To continue reading for free, register below or login
To read more you must become a member of SearchSQLServer.com
');
// -->

Much like CLR user-defined types (UDTs) XML is now a new first-class data type in SQL Server 2005. Developers may now be tempted to use this data type to avoid having to write code to "shred" XML data into tables (i.e. instead of using OPENXML to populate tables with the data).
Unfortunately, using the XML data type like this has many of the same problems as representing data in user-defined types. Developers should keep performance in mind, as querying a node of an XML column will require the engine to evaluate a separate XML query for each row of the table. Normalization issues are also present, similar to using CLR UDTs. Ensuring data integrity will be extremely difficult in databases that make too much use of the XML data type.
Do you have comments on this Ask the Expert Q&A? Let us know.
|