Hello Matt, Are you receiving any indexing errors in your logs (check the Solr logs as well)? To be sure, I just wrote a test (using our erlang pb api, https://github.com/basho/yokozuna/pull/474/files#diff-5d0015658ff90b94cb1a00329ffafe00R251 <https://github.com/basho/yokozuna/pull/474/files#diff-5d0015658ff90b94cb1a00329ffafe00R251>) using a custom schema, and I didn’t run into any troubles; I also checked via the http api. If you have the required _yz* fields, you should get those back with the document. If you want the groups items themselves, you’d have to make `stored` true.
Zeeshan Lakhani programmer | software engineer at @basho | org. member/founder of @papers_we_love | paperswelove.org twitter => @zeeshanlakhani > On Mar 22, 2015, at 4:13 PM, Matt Brooks <mtbrook...@gmail.com> wrote: > > Hello, > > I have a quick question about a search schema that would index an array of > strings in a JSON object. I am storing user data in JSON that looks something > like this: > > { > "name" : "John Smith", > "email" : "jsm...@gmail.com <mailto:jsm...@gmail.com>", > "groups" : [ > "3304cf79", > "abe155cf" > ] > } > The custom schema I use for users includes this field entry: > > <field name="groups" type="string" indexed="true" stored="false" > multiValued="true"/> > I also have the following field type entry: > > <fieldType name="string" class="solr.StrField" sortMissingLast="true"/> > I assumed that these entries would allow me to search for users using a query > like: > > curl $RIAK/search/query/user?wt=json&q=groups:3304cf79 > But no docs are returned. I'm almost certain I have an issue with my schema. > How can I query users by string entries in the "groups" array? > > Thank you, > Matt. > > _______________________________________________ > 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