Riak python client and Solr

Sapre, Meghna A meghna.a.sapre at intel.com
Tue Aug 19 16:45:33 EDT 2014

Thanks Eric,
  It throws errors for 'group.field'='build.version'.

search_results = riak_client.fulltext_search(self.Result_Index, 'build.type:CI', group='on', 'group.field'='build.version')
Cannot appear past keyword arguments.

I tried some variations of the same, did not seem to work
Any suggestions?


From: Eric Redmond [mailto:eredmond at basho.com]
Sent: Tuesday, August 19, 2014 1:12 PM
To: Sapre, Meghna A
Cc: riak-users
Subject: Re: Riak python client and Solr

You don't pass in a query as a url encoded string, but rather a set of parameters. So you'd call something like:

search_results = riak_client.fulltext_search(self.Result_Index, 'build.type:CI', group='on', 'group.field'='build.version')


On Aug 19, 2014, at 1:08 PM, Sapre, Meghna A <meghna.a.sapre at intel.com<mailto:meghna.a.sapre at intel.com>> wrote:

  I am trying to use the group and stats options with riak search. I get expected results with http urls, but not with python-riak-client fulltext pbc search.
Here's what I'm trying to do:

q = 'build.type:CI&group=on&group.field=build.version'
                    search_results = riak_client.fulltext_search(self.Result_Index, q)
               except Exception as e:
                    print e

This throws an error: no field name specified in query and no default specified via 'df' param.

The same query string works without the group options, and the complete string works in the http API.
Any suggestions on how to make this work?


riak-users mailing list
riak-users at lists.basho.com<mailto:riak-users at lists.basho.com>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.basho.com/pipermail/riak-users_lists.basho.com/attachments/20140819/fc3b2bf0/attachment.html>

More information about the riak-users mailing list