lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shawn Heisey <apa...@elyograg.org>
Subject Re: term frequency solrj
Date Tue, 10 Jan 2017 05:03:23 GMT
On 1/9/2017 6:31 AM, huda barakat wrote:
> Can anybody help me, I need to get term frequency for a specific
> filed, I use the techproduct example and I use this code:

The variable "terms" is null on line 29, which is why you are getting
NullPointerException.

> query.setRequestHandler("terms"); 

One possible problem is setting the request handler to "terms" ...
chances are that this should be "/terms" instead.  Handler names in your
config will most likely start with a forward slash, because if they
don't, a typical example config in version 3.6 and later doesn't allow
any way for them to be used.  Since 3.6, "handleSelect" is set to false
in all examples, and it should be left at false.

Thanks,
Shawn


Mime
View raw message