I run an XQuery in Berkeley which start as
Code: Select all
declare variable $set_1:= collection("set_1.dbxml")/TOUCH[PRR/X_COORD=$x and PRR/Y_COORD=$y];
declare variable $set_2:= collection("set_2.dbxml")/TOUCH[PRR/X_COORD=$x and PRR/Y_COORD=$y];
But when I use Berkeley just to extract two files set_1.xml and set_2.xml, this takes ~6s only (due to indices on X_COORD and Y_COORD). When I then run the same query body with Saxon on the two files set_1.xml and set_2.xml, Saxon returns after ~9s. So, total execution (6+9)=15s compared to 170s in native Berkeley.
(I also run the same from a perl script using Sleepycat::DbXML and gave Berkeley a cache of 64M; performance improved slightly to approx. 140s)
- Is this performance difference expected
- ... where does it come from?