Welcome Guest! Log in


Symptom

The sqlToParameters action fails with the following error: "The content of elements must consist of well-formed character data or markup".

Sample stack trace:

sqlToParametersWithInferiorOperator/SqlToParameters
org.xml.sax.SAXParseException; lineNumber: 4; columnNumber: 38; The content of elements must consist of well-formed character data or markup.
    at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:257)
    at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:347)
    at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:121)
    at com.indy.engine.actionCodes.sqlToParameters.getDocumentFromXmlPart(SourceFile:106)
    at com.indy.engine.actionCodes.sqlToParameters.executeSimpleCode(SourceFile:262)
    at com.indy.engine.action.common.ActionCodeTypeI.executeCode(SourceFile:1646)
    at com.indy.engine.action.common.ActionCodeTypeI.run(SourceFile:1805)
    at java.lang.Thread.run(Thread.java:745)

Solution

Your query expression might contain XML-specific characters, like "<" or ">".

Replace them with their entities: "&lt;" or "&gt;" respectively.

Sample expression:

<sqlToParameters>
<parameter name="/testHtml_${CORE_NAME}$" type="String">
select val from %x{$keyval/tech:physicalPath()}x%
where keycode &lt; 'toto'
limit 1
</parameter>
</sqlToParameters>

You have no rights to post comments

Knowledge Base

Suggest a new Article!