The differences lie in Lucene. Instead of thinking of phrase queries as slow, think of term queries as fast :-) Phrase queries need to read and consider position information that term queries do not.
-Yonik On 10/26/07, Haishan Chen <[EMAIL PROTECTED]> wrote: > I am a new Solr user and wonder if anyone can help me these questions. I used > Solr to index about two million documents and query on it using standard > request handler. I disabled all cache. I found phrase query was substantially > slower than the usual query. The statistic I collected is as following. I > was doing the query on the one field only. content:(auto repair) > 47 ms repeatablecontent:("auto repair") 937 ms > repeatablecontent:("auto repair"~10000) 766 ms repeatable What are the > factors affecting phrase query performance? How come the phrase query > content:("auto repair") is almost 20 times slower than content:(auto repair)? > I also notice a the phrase query with a slop is always faster than the one > without a slop. Is the difference I observe here a performance problem of > Lucene or Solr? > > It will be appreciated if anyone can help