"By default, the PATH mode generates element-centric XML."This is not true. It follows the logic described above. If a column name e.g. starts with @, FOR XML PATH tries to render it as an attribute.The sentence should be something like "By default, the PATH mode uses the column name to decide how to render a column."Of course the column names usually do not contain @ or /, that why it seems the "element-centric" XML is the default output.goif object_id('tempdb..#Test') is not null drop table #T
↧