FOR XML Support for the User-Defined Data Types (UDT)

FOR XML does not support common language runtime (CLR) user-defined data types (UDTs).

To use FOR XML with CLR user-defined data types, make sure that the data type has an XML serialization, and use an explicit cast to XML in the FOR XML select clause.