I have a JCR query like:
SELECT * FROM [my:nodetype] WHERE ISDESCENDANTNODE([/somepath]) OR (otherPath LIKE '/someotherpath')
It executes in 6 seconds.
The otherPath
property is a multivalue string property (only two object have it set).
There are ONLY 7 total nodes of type my:nodetype
in the whole database
While both separate queries:
SELECT * FROM [my:nodetype] WHERE ISDESCENDANTNODE([/somepath])
And
SELECT * FROM [my:nodetype] WHERE otherPath LIKE '/someotherpath'
Execute in times less than 1ms. Is there any reason why the first query runs so slow? Maybe there is a possibility to see a query plan in Jackrabbit just as with SQL databases? How can i debug the problem?
I cannot imagine why searching through 7 nodes in total, no matter the search criteria would produce 7 second query run time...