Reputation: 4251
I have xml files I want to read in and store in the database. Linq to sql requires the data to be sent in using an xelement, but if I send in the data this
new XElement("build", BuildNode.InnerXml)
I end up with data looking like this in the database lt;..gt;.. It converts the brackets into lt; and gt; which then makes the data useless from a xml standpoint.
Any ideas on how to get the xml data inside the xml column?
Upvotes: 2
Views: 1206
Reputation: 2033
Looks like you should use XElement.Parse(BuildNode.InnerXml) instead of just passing the raw property in.
Upvotes: 2