1

I'm trying to extract the first occurrence in an xml message like this;

NVL(EXTRACTVALUE(message,'//ElementValue[1]'),NULL) as ElementValue 

I get error:

XML - ORA-19025: EXTRACTVALUE returns value of only one node.

Any suggestions?

1 Answer 1

1

Currently, the XPath would return every first ElementValue in a parent element. To actually return only the first occurrence of ElementValue in the entire document, you need to use parentheses before position index :

(//ElementValue)[1] 

Also read @Dimitre Novatchev's answer here

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.