Category Archives: apigee

Usergrid query on unknown sub properties

I'm trying to query a collection of data with entities that contain the "related" property:

...,{ related : 
       { global: [{name: "foo"}, {name: "bar"}] },
       { local: [{name: "bar"}] },
       { random: [{name: "foo"}] },
       { dingbat: [{name: "baz"}] },
    }

I want to write a query which selects all entities which have name="foo" anywhere within the related property.

I can do this just fine:

select * where related.global.name='foo'

However there could be any number of keys within the "related" property so I can't just AND them all into a single query. Trying to do something like this (which doesn't work)

select * where related.*.name='foo'

Is there any way to achieve this?

Query with "the" not returning results

I'm trying to select an entity with "The" as the first word of the title attribute but Usergrid seems to be ignoring it.

For example, this query which is attempting to select "The Giver"

/books?ql=select * where title contains 'the*' //returns no results
/books?ql=select * where title contains 'giver*' //returns "The Giver"

Is this be design? Why is "the" ignored? Is it some kind of keyword? How could I work around this apparent limitation?

Apache Usergrid Link Issues

On the Usergrid main docs page The following links return a 404 Error. Does anybody know where the open-source version of the Admin Portal is (as is referenced on the Apache site)? Is the Apigee portal the only one?

https://usergrid.incubator.apache.org/admin-portal
https://usergrid.incubator.apache.org/organization
https://usergrid.incubator.apache.org/queries-and-parameters

Thank you in advance.