Hi:

I do want to add that the reason I am still using iBatis is due to one of the basic goals.....it does 80% of the JDBC work for me.

The one unique requirement, that I have outlined will not prevent me from using iBatis.

Thanks,
Edwin

----- Original Message ----- From: "Larry Meadors" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Thursday, June 22, 2006 9:54 PM
Subject: Re: sql map via Java API


The advantages would be parameter mapping, resource management, and
result mapping.

The disadvantages are the increased potential for sql injection, a
slight loss of performance, and potentially less concrete results (if
you are putting them into a Map).

Larry


On 6/22/06, Yusuf <[EMAIL PROTECTED]> wrote:
just my opinion,
but what's the point of using iBatis if you wanted to build a statement
at runtime?
maybe you can just use simple jdbc?

yusuf

-----Original Message-----
From: Edwin Lukaweski [mailto:[EMAIL PROTECTED]
Sent: Friday, June 23, 2006 3:28 AM
To: [email protected]
Subject: Re: sql map via Java API


Yes - good one!!!

    However, just to carry this a bit further, ideally, I would like to
have
iBatis prepare this once and then use the prepared statement.

    As I understand it, 'remapResults=true' will force a lot of work due
to
examining the result set meta data. Also, I would imagine that the
$generatedSqlStatement$ will also be prepared on each call.

    I guess I could go straight to the JDBC driver but will that
interfere
with iBatis' operation?

Thanks,
Edwin

----- Original Message -----
From: "Larry Meadors" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Thursday, June 22, 2006 2:52 PM
Subject: Re: sql map via Java API


> Yeah, it's risky, but life is about risks, right? :-)
>
> <select id="injectMeBaby"
> remapResults="true">$generatedSqlStatement$</select>
>
> Larry
>
>
> On 6/22/06, Edwin Lukaweski <[EMAIL PROTECTED]> wrote:
>>
>>
>> Hi:
>>
>>     Is there any way of submitting a new <select>.....</select> SQL
Map
>> snippet via the Java API. Or, alternatively, is there a way of
>> contructing
>> an object, from iBatis, that accomplishes the same thing?
>>     What I am trying to do is build a SELECT statement at execution
time,
>> based on parameters entered, but after ibatis has been initialized. I

>> would
>> then like to load it into an SQL-MAP for a specific table (namespace
ID)
>> and
>> then use the standard interface calls.
>>
>> Thanks,
>> Edwin
>>
>






Reply via email to