ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrey Rogov" <konu...@gmail.com>
Subject RE: Ibatis sql question
Date Fri, 24 Jul 2009 13:05:59 GMT
Sorry.

 

<isEqual prepend="and" property="maxprice" compareValue="1">
       price BETWEEN #price# AND #maxprice#
</isEqual>
<isEqual prepend="and" property="maxprice" compareValue="0">
       price =#price# OR price=#maxprice#
</isEqual>




  _____  

From: Sergey Livanov [mailto:sergey.livanov@gmail.com] 
Sent: Friday, July 24, 2009 3:32 PM
To: user-java@ibatis.apache.org
Subject: Re: Ibatis sql question

 

<isNotEqual prepend="#parameter#" property="maxprice" compareValue="1">
       price BETWEEN #price# AND #maxprice#
</isNotEqual>
<isNotEqual prepend="#parameter#" property="maxprice" compareValue="0">
       price =#price# OR price=#maxprice#
</isNotEqual>





2009/7/24 Odelya YomTov <odelya@jpost.com>

Hi!

I would like to get a parameter in my sql and by that to decide if to use
prepend="OR" or prepend="AND"

<isNotEqual prepend="<here to write the parameter of the query>"
property="maxprice"
                               compareValue="0">
                               price BETWEEN #price# AND #maxprice#
                       </isNotEqual>

How can I do it?



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

 


Mime
View raw message