db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Bowen <s...@yahoo.com>
Subject Somewhat complex query with Criteria
Date Mon, 31 Jan 2005 09:36:13 GMT
I am trying to execute the following query:

SELECT * FROM notification WHERE
( (code=0) OR
(code <>0) AND (type='C') )

I have tried (I think) every possible combination of
Criteria.add, Criteria.and and Criteria.or and I can't
get it to spit out the correct SQL code. It keeps
putting:

WHERE type='C'

at the beginning of the query and then lumping
together the "code" part:

( (code=0) AND (code<>0) )

Anyone have a clue how I can do this? I would prefer
not to use executeQuery() instead ...

Many thanks!
syg


		
__________________________________ 
Do you Yahoo!? 
Take Yahoo! Mail with you! Get it on your mobile phone. 
http://mobile.yahoo.com/maildemo 

---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


Mime
View raw message