linq to sql - Can I get around "There are multiple root elements"? -
i'm working database have no control over, 1 column xml type, , contains, yep, multiple root elements. linq throws exception.
i understand error , why, can't control data. i'd rather not tweak auto-generated code.
is there way around exception?
you can use subselect add root element younr xml-string:
select concat("<mynewroot>",mxmlcolumn,"</mynewroot>") (select * mytable);
i know sql syntax , no linq-syntax should possible in linq, hoep idea.
an other way not let linq interpret xml column xml string, or let interpret xml xml-fragment.
Comments
Post a Comment