lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stephane Bailliez <sbaill...@apache.org>
Subject Sorting by field from a given 'offset'
Date Fri, 24 Jun 2005 12:42:45 GMT
Hi all,


I'm trying to do the following:

"starting from document that has field f1 = a, give me the first n 
documents sorted by field 'z' ordered by asc/desc"

Is it possible to build a complex query more efficient than:

1) search for the document where f1 = a
2) get the field f2 from this document
3) give me the nth sorted documents (in either asc or desc order)


In sql that would be something like:

select LIMIT 0 count * from table where f2 < (SELECT f2 FROM table WHERE 
f1 = 'a') order by f2 desc


Thanks

Stephane


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message