ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Larry Meadors" <lmead...@apache.org>
Subject Re: SQL request with optional "where"
Date Wed, 14 Jun 2006 20:44:10 GMT
Use dynamic sql after looking at the tutorial and developer giude.

Larry


On 6/14/06, xianwinwin <xianwinwin@gmail.com> wrote:
>
> Hi guys,
>
> In the old days, where I used to work with JDBC, I had a GUI where the
> end-user could have request for info such as:
>
> What is the production of user: ABC located in DEF between DATEA and DATEB?
>
> According to the request I produced the query (e.g., if the user has
> specified location, the query would have the statement – WHERE LOCATION
> ='DEF', if he didn't specify it I would not put that statement). The bottom
> line: I would create one query based on the user's request.
>
> In iBatis, how can I do that? I mean I don't want to create multiple queries
> to handle the user's request.
>
> Anyone have a better idea?
> Thanks
>
>
> --
> View this message in context: http://www.nabble.com/SQL-request-with-optional-%22where%22-t1788471.html#a4872351
> Sent from the iBATIS - User - Java forum at Nabble.com.
>
>

Mime
View raw message