Kiran: Please start a new thread when asking a new question. From Hossman's apache page:
When starting a new discussion on a mailing list, please do not reply to an existing message, instead start a fresh email. Even if you change the subject line of your email, other mail headers still track which thread you replied to and your question is "hidden" in that thread and gets less attention. It makes following discussions in the mailing list archives particularly difficult. See Also: http://en.wikipedia.org/wiki/User:DonDiego/Thread_hijacking On Wed, Jul 14, 2010 at 10:56 AM, Kiran Kumar <muthoj...@gmail.com> wrote: > All, > > Issue: Unable to get the proper results after searching. I added sample > code > which I used in the application. > > If I used *numHitPerPage* value as 1000 its giving expected results. > ex: The expected results is 32 docs but showing 32 docs > Instead If I use *numHitPerPage* as 2^32-1 its not giving expected results. > ex: The expected results is 32 docs but showing only 29 docs. > > Sample code below: > > > StandardAnalyzer analyzer = new StandardAnalyzer(Version.LUCENE_CURRENT); > QueryParser qp = new QueryParser(Version.LUCENE_CURRENT, defField, > analyzer); > Query q = qp.parse(queryString); > TopDocsCollector tdc = TopScoreDocCollector.create(*numHitPerPage*, true); > IndexSearcher(is).search(q,tdc); > > ScoreDocs[] noDocs = tdc.topDocs().scoreDocs; > > Please let me know if any other way to search? > > Thanks. > Kiran. M >