On Sat, 2009-08-08 at 19:37 -0400, Drew Jensen wrote:
> Ok there is a problem.
> 
> This time I am using JDBC 5.1.6
> 
> If I construct my query this way:
> 
> SELECT `Date`, weekday( `Date` ) 
> 
> FROM `MSIS`.`precipitation` AS `precipitation` 
> 
> WHERE `precipt` > 0 
> 
>     AND   ( weekday( `Date` ) = '4' 
> 
>                  OR weekday( `Date` ) = '5' 
> 
>                  OR weekday( `Date` ) = '6' 
> 
>                )
> 
> 
> No problem
> 
> But as soon as I flip it aroung the way you have it
> 
> SELECT `Date`, weekday( `Date` ) 
> 
> FROM `MSIS`.`precipitation` AS `precipitation` 
> 
> WHERE ( weekday( `Date` ) = '4' 
> 
>         OR weekday( `Date` ) = '5' 
> 
>         OR weekday( `Date` ) = '6' 
> 
>        )
> AND `precipt` > 0 
> 
> 
> Then I get a syntax error bringing it into the designer...

Interesting....

So it matters what order the "ands" and "ors" are in?

Keith



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to