jMotta,

You can make OR queries using lists.
The datastore will run one query for each parameter and then join the
results for you.

Like I said: ofy.query(Obj.class).filter("name in", Arrays.asList("name1",
"name2")).list();

works like a champ :)

Regards,



On Mon, Jul 4, 2011 at 6:01 PM, jMotta <[email protected]> wrote:

> Until where I know, there is no feature to accomplish the OR, AND is
> implicit when you add more filters.
>
> IS NULL is equals to .filter("attr", null);
> IS NOT NULL is equals to .filter("attr !=" null);
>
> If you find something about doing OR, let us know! :)
>
> *Jayr Motta*
> Software Developer
> *
> *
> I'm  on 
> BlackBeltFactory.com<http://www.blackbeltfactory.com/ui#!User/jmotta/ref=jmotta>
> !
>
>
>
> On Mon, Jul 4, 2011 at 5:30 PM, hadf <[email protected]> wrote:
>
>> Hello,
>>
>> Two questions :
>>
>> How can I filter a query with logical constraints (or, and) ? (where
>> attribut = foo1 or attribut = foo2)
>> And furthermore, how can I filter a query with null or non null
>> values ? (where attribut is null / where attribut is not null)
>>
>> Thank you for your help :)
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Google App Engine for Java" group.
>> To post to this group, send email to
>> [email protected].
>> To unsubscribe from this group, send email to
>> [email protected].
>> For more options, visit this group at
>> http://groups.google.com/group/google-appengine-java?hl=en.
>>
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google App Engine for Java" group.
> To post to this group, send email to
> [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/google-appengine-java?hl=en.
>



-- 
Bruno Fuster

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to