Re: SortedNumericDocValuesFIeld

2016-05-31 Thread Chitra R
Hi, Could you please explain how to store the SortedNumericDocValuesField to include in the code? Thanks, Chitra On Tue, May 31, 2016 at 3:02 PM, Chitra R wrote: > Thanks. > > On Fri, May 27, 2016 at 6:02 PM, Adrien Grand wrote: > >> DocValues.getSortedNumeric is indeed not really us

Re: SortedNumericDocValuesFIeld

2016-05-31 Thread Chitra R
Thanks. On Fri, May 27, 2016 at 6:02 PM, Adrien Grand wrote: > DocValues.getSortedNumeric is indeed not really useful for high-level code, > such as you example which is getting the sort values for each top hit. > However, if you wanted to implement lower level functionality like building >

Re: SortedNumericDocValuesFIeld

2016-05-27 Thread Adrien Grand
DocValues.getSortedNumeric is indeed not really useful for high-level code, such as you example which is getting the sort values for each top hit. However, if you wanted to implement lower level functionality like building a histogram of the prices of all matching documents, you would need to build

Re: SortedNumericDocValuesFIeld

2016-05-27 Thread Chitra R
Hi, i have achieved the same sorting using Sort sort = new Sort(new SortedNumericSortField("Numericdoc_price", > SortField.Type.LONG,true)); > int maxDoc = searcher.getIndexReader().maxDoc(); > TopFieldDocs topdocs =searcher.search(query, 10,sort); > > for (ScoreDo

Re: SortedNumericDocValuesFIeld

2016-05-27 Thread Chitra R
Hi, Actually I like to print the sorted numeric list from the sortedDocValues and I dont know which api have to use . Could you please help me to achieve this? Thanks, Chitra On Thu, May 26, 2016 at 8:17 PM, Michael McCandless < luc...@mikemccandless.com> wrote: > This looks about right ..

Re: SortedNumericDocValuesFIeld

2016-05-26 Thread Michael McCandless
This looks about right ... did something go wrong? Mike McCandless http://blog.mikemccandless.com On Thu, May 26, 2016 at 9:29 AM, Chitra R wrote: > Hi, > I am new to lucene. Anyone please explain how to sort the numeric > values by SortedNumericDocValuesField? > > I tried like this usin