", "<...">

SQL Server XQuery: how to avoid the "illegal qualified name" exception?

I am working on XQuery, which may / may contain characters like ">", "<" and single quotes.

How to avoid breaking xml parser?

My xml form is like this

<root>
<container>
  <item>(d.Field <> 0)</item>
</container>
</root>
+3
source share
1 answer

The "XML" you specified is not XML.

Any of the following will be XML:

<root>
<container>
  <item>(d.Field &lt;&gt; 0)</item>
</container>
</root>

or

<root>
<container>
  <item><![CDATA[(d.Field <> 0)]]></item>
</container>
</root>
+12
source

Source: https://habr.com/ru/post/1791157/


All Articles