[ 
https://issues.apache.org/jira/browse/USERGRID-951?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14717135#comment-14717135
 ] 

Brandon Shelley edited comment on USERGRID-951 at 8/27/15 5:40 PM:
-------------------------------------------------------------------

AND statements are joined with priority over OR statements in both 1.0 and 2.0. 
For example:

{code}where name = 'bob' or name = 'joe' and created = 1440697016{code}

breaks down to:

{code}where name = 'bob'
OR
where name = 'joe' and created = 1440697016{code}

To mitigate an issue where you need created to apply on both sides of the OR 
statement:

{code}where name = 'bob' and created = 1440697016
OR
where name = 'joe' and created = 1440697016{code}

Need to get this added to docs.


was (Author: brandonshelley):
AND statements are joined with priority over OR statements in both 1.0 and 2.0. 
For example:

{code}where name = 'bob' or name = 'joe' and created = 1440697016{code}

breaks down to:

{code}where name = 'bob'
OR
where name = 'joe' and created = 1440697016{code}

To mitigate an issue where you need created to apply on both sides of the OR 
statement:

{code}where name = 'bob' and created = 1440697016
OR
where name = 'joe' and created = 1440697016{code}

> Update documentation to reflect order of operations
> ---------------------------------------------------
>
>                 Key: USERGRID-951
>                 URL: https://issues.apache.org/jira/browse/USERGRID-951
>             Project: Usergrid
>          Issue Type: Story
>            Reporter: Jeffrey 
>            Assignee: Brandon Shelley
>
> For example, what is the result of "where A or B and C"?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to