• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Searching XML Doc AND checking for existence

New Here ,
Dec 27, 2007 Dec 27, 2007

Copy link to clipboard

Copied

I have the following code for parsing and searching an XML document. As long as the XML document contains the Objective Element it works fine. However, the XML document does not always have an Objective Element and when it doesn't I get the following error.
"Element OBJECTIVE.XMLTEXT is undefined in a Java object of type class coldfusion.xml.XmlNodeMap referenced as "
I have tried sever times to qualify the expression within a <cfif ISDEFINED> without success. Does any one know how to check for the existence of the Objective Element to stop this error.
TOPICS
Advanced techniques

Views

226

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Dec 27, 2007 Dec 27, 2007

Copy link to clipboard

Copied

LATEST
Change you xpath so that you're only returning the StructuredXmlResume
nodes that *have* an Object node.

--
Adam

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation