Mike,

you need to make sure the followers field is marked as a numeric field in the 
bucket's schema in Riak Search. You can do that by either relying on the 
default schema and appending _num to the field name, so it'd be followers_num 
instead of followers in the JSON you're generating.

Or you could set your own custom schema for the bucket, telling Riak Search to 
treat the followers field as a numeric field. Both is detailed on our wiki: 
http://wiki.basho.com/Riak-Search---Schema.html

Mathias Meyer
Developer Advocate, Basho Technologies

On Dienstag, 5. April 2011 at 03:14, Mike Stoddart wrote: 
> I'm installing the lakes/celtics twitter data linked through Basho's
> site. I can get some basic text searches to work, but I'm seeing some
> weird results from numerical range queries:
> 
> search_query = client.search('stuff', 'followers:[140 TO 150]')
> 
> Name:Kevin Shpunt Term:lakers Followers:146
> Name:Carlos Ordonez Term:lakers Followers:15
> Name:Kelvin Shortt Jr Term:lakers,celtics Followers:140
> Name:Stanley T. Davis Term:lakers Followers:15
> Name:John Robertson Term:lakers Followers:141
> Name:Steven Wineglass Term:lakers Followers:1493
> Name:Badral Jambal Term:lakers Followers:1432
> 
> Am I doing something wrong?
> 
> Thanks
> Mike
> 
> _______________________________________________
> riak-users mailing list
> riak-users@lists.basho.com
> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
> 


_______________________________________________
riak-users mailing list
riak-users@lists.basho.com
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

Reply via email to