Hello Luigi, I am using orientdb-community-2.0.3. I will try this out in 2.1 then.
Thanks for your response. regards, Chandima On Thursday, May 21, 2015 at 7:38:57 PM UTC+5:30, Luigi Dell'Aquila wrote: > > Hi Chandima, > > which OrientDB version? I think it should be fixed in 2.1 rc, but I'd like > your confirmation... > > Luigi > > > 2015-05-21 15:53 GMT+02:00 Chandima Jayawickrema <[email protected] > <javascript:>>: > >> Hello, >> >> I just observed a massive performance difference for below 2 JavaScript >> based OrientDB server functions statements. >> >> 1. db.query('SELECT count(*) FROM Employee WHERE department=? LIMIT 50', >> '#10:1'); >> >> 2. db.query('SELECT count(*) FROM Employee WHERE department=#10:1 LIMIT >> 50'); >> >> #1 takes more than 2 minutes for 1 million records but #2 comes in about >> less than 200 milliseconds!!!! >> For this Department (#10:1) only 100,000 records exist but note that i am >> also limiting it to 50. It looks like in #1 all the records are being >> fetched before query applies the parameter. >> I even get the console warning stating 'more than 500,000 records are >> being fetched' >> >> I have also applied a NON-UNIQUE HASH INDEX for Employee's department >> link field. >> >> Wondering if i am using the parametarized query wrong. Please advise... >> >> regards, >> Chandima >> >> -- >> >> --- >> You received this message because you are subscribed to the Google Groups >> "OrientDB" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> > > -- --- You received this message because you are subscribed to the Google Groups "OrientDB" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
