I am new with eXist and xPath. I am trying to use the lowercase function. Here's my java code.
CompiledExpression compiled = xQueryService.compile("/realestatedata/agents/author/name[lower_case(text())='" + authorName.toLowerCase() + "']");
It gives the following error.
Caused by: org.exist.xquery.XPathException: exerr:ERROR err:XPST0017 Function lower_case() is not defined in module namespace: http://www.w3.org/2005/xpath-functions [at line 1, column 36] [at line 1, column 36]
I read in the documentation that modules have to be included so I put the following in conf.xml under xquery->builtin-modules.
<module uri="http://www.w3.org/2005/xpath-functions" class="org.exist.xquery.functions.fn.FnModule" />
I am getting the same error after an exist restart. I've also tried changing the XQueryService from org.xmldb.api.modules.XQueryService
to org.xmldb.api.modules.XMLResource