cancel
Showing results for 
Search instead for 
Did you mean: 

JAVA XML DOM4J: Invalid XPath expression

Former Member
0 Kudos

Hi everybody,

I am not sure why I am getting an exception for this expression:

Number count= document.numberValueOf("/NODE/SUBNODE/count(*)");

Exception is:

org.dom4j.InvalidXPathException: Invalid XPath expression:

Thanks regards

Mario

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hello

what about

"count (/NODE/SUBNODE)" as xpath expression

regards franz

reward points if useful

Former Member
0 Kudos

Hi Franz,

a 10-Pointer!

But the other way should also work according to W3C

It worked in XMLSPY!

Thanks, Regards Mario

Answers (0)