sounds like you want CouchDB Lucene for fulltext queries: http://github.com/rnewson/couchdb-lucene
On Jul 1, 2010, at 3:00 PM, afshin afzali wrote: > This is ok, But in real world my problem is more complicated. In my project, > there is a CONTACT document that will contains all information that somebody > may has: Name(First, Middle, Last, Nick), Phone(Home, Work, Cell..) > Addresses(Home, Work, ...) Emails, IM(s), ... So we should provide a search > page which contains all search items that user may use to retrieve desired > contact. I was thinking that I could emit all of searchable information of > CONTACT document, then when I query my view just insert those data which > provided by user and use some don't care notaion for others :( > > -- afshin > > On Fri, Jul 2, 2010 at 2:15 AM, Robert Newson <[email protected]>wrote: > >> You'll need to emit the last name first so that the items with the >> same last name sort together. >> >> function(doc) { >> emit([doc.lastname, doc.firstname], null); >> } >> >> and then query with ?startkey=["Afzali"]&endkey=["Afzali",{}] >> >> more simply; >> >> function(doc) { >> emit(doc.lastname, null); >> } >> >> and then query with ?key="Afzali" >> >> B. >> >> >> On Thu, Jul 1, 2010 at 10:29 PM, afshin afzali <[email protected]> >> wrote: >>> Sorry, But I don't know why list rejects my post!!! >>> >>> Ok, assume we have three object keys which emited by a view; >>> >>> { "FirstName" : "Afshin", "LastName" : "Afzali" } >>> { "FirstName" : "Omid", "LastName" : "Afzali" } >>> { "FirstName" : "Ashkan", "LastName" : "Afzali" } >>> >>> I want to retreive all docs which have LastName == "Afzali" >>> -- afshin >>> >>
