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 Ryan McKinley <ry...@gmail.com> on 2008/01/15 21:48:58 UTC

Re: best way to get number of documents in a Solr index

try a query with q=*:*

the 'numFound' will be every document -- use &rows=0 to avoid returing 
docs (if you like)

ryan


Maria Mosolova wrote:
> Hello,
> 
> I am looking for the best way to get the number of documents in a Solr 
> index. I'd like to do it from a java code using solrj. Any suggestions 
> are welcome.
> 
> Thank you in advance,
> Maria mosolova
>