Thanks for all the ideas posted back. Follow [EMAIL PROTECTED]'s hint, after I enabled plugin query_more, everything worked well.
I had only enabled plugin index-more which only cover the index part. To search by date, query_more has to be enabled also. I thought any indexed field should be searchable like luke did, obviously I was wrong. But, does this mean if I want to add any additional search field that not covered in index_more, I have to write two plugins, one for index and one for query? It seems to me this is a very common task, would be nice if it's a configurable feature. On Sun, 2007-08-26 at 21:15 -0400, Erick Erickson wrote: > Your first query searches over the field site for > lucene.apache.org and apache. > > Your second query searches over the field date > for all those terms, and I assume apache isn't > in your date field. > > Luke use a default field a bit differently, and > searched your dates in the date field and > whatever your default field was for apache. The > "update" button in Luke is very helpful here, as > is the toString() method on queries in your program. > > The toString() method is what I go to first when > queries don't give me what I expect....... > > Best > Erick > > > On 8/26/07, kevin chen <[EMAIL PROTECTED]> wrote: > Hi, guys > > I am very puzzled by the searching by field. > > I can successfully do following query: > > site:lucene.apache.org "apache" > which returned 20 hits. > > But, following query retured 0 hit. > > date:20070101-20070701 "apache" > > Using luke, query the same index using query > date:20070101-20070701 apache > returned 2 documents. > > What did I miss here? is there some logics implemented for > "site:" > keyword that I have to do for other keyword? > > --Kevin > > >
