You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by a8...@yahoo.com on 2010/01/30 00:20:11 UTC

sort items by whether the user has viewed it or not

hi,

i want to query for documents that have certain values but i want it first sorted by documents that this person has viewed in the past.  i can't store each user's view information in the document so i want to pass that in to the search.  is it possible to do something like this:

http://solr?q=baseball&sort=doc_isbn("ABC" or "DEF" or "GHI") desc, title desc

any help is appreciated,
r


Re: sort items by whether the user has viewed it or not

Posted by Wangsheng Mei <ha...@gmail.com>.
You can try to use boost query(bq) instead of sort.
They should have similar effect.

e.g.
http://solr?q=baseball&bq=isbn:ABC+isbn:DEF+isbn:GHI&qt=dismax

2010/1/30 <a8...@yahoo.com>

> hi,
>
> i want to query for documents that have certain values but i want it first
> sorted by documents that this person has viewed in the past.  i can't store
> each user's view information in the document so i want to pass that in to
> the search.  is it possible to do something like this:
>
> http://solr?q=baseball&sort=doc_isbn("ABC" or "DEF" or "GHI") desc, title
> desc
>
> any help is appreciated,
> r
>
>


-- 
梅旺生