Riak Search Using Riak Erlang Client

Jorge Garrido jorge.garrido at morelosoft.com
Fri Jan 18 14:50:12 EST 2013


Hi 

I've implemented a riak search using riak-erlang-client like this:

First I put an object into Riak using erlang:

	$ erl -pa ....
	
	> ObjUser1 = riakc_obj:new(<<”users”>>, <<”user_one”>>, [{name, mario}, {age, 10}]).
      ....
      > riakc_pb_socket:put(Pid, ObjUser1).
      ok

Now when I try a search:

	> riakc_pb_socket:search(Pid, <<"users_data">>, <<"name:mario">>).
	....

it works, but if my object value is a proplist like this:

	[{name, "MARIO"},.....]

so, the values of each key in the proplist is a string

the question is: how can I make a query for this?

Thanks

Jorge Garrido
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.basho.com/pipermail/riak-users_lists.basho.com/attachments/20130118/26cef262/attachment.html>


More information about the riak-users mailing list