Hi, Easiest solution will be to add a field with creation/insertion date. you can use DateField static methods for converting the date to a string for indexing. You can also use NumericFields if you're using version 2.9.1 which will allow for fast date range searches.
When runing a search, pass a sort object on that date field. Try searching the archives (.net and java ones) - this question was discussed a few times before. Eran. On Tue, Dec 22, 2009 at 1:18 PM, Robert Pohl <[email protected]> wrote: > Hi all, > > Is there a way to boost index position? > I want to achieve a result that is basically sorted by the latest (added to > the index) on top, as well as text relevance. > For example I search for tiger woods, and don't want articles from last > year (in the first places). > > Thanks, > Rob > >
