ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From joson yu <yuqian...@gmail.com>
Subject Re: how to get the sql string
Date Tue, 26 May 2009 11:18:00 GMT
hi,Popa:
     really thanks for your reply.
     my really purpose is to get the SQLs,then i will save the SQLs as my
system log infomation. i thourght is there any method in the ibatis to get
the sql.but i have find it,and don't get the answer.

2009/5/26 Alin Popa <alin.popa@gmail.com>

> Hi Joson,
>
> Afaik, the only way to display the executed query is by enabling logging
> for Connection ... etc.
> It will display the queries before preparation.
> As a workaround, I enable sql logging for server (mysql in my case).
> Indeed, it will really help if ibatis can display the SQLs in an explicit
> way (maybe something like hibernate does ?).
>
>
> On Tue, May 26, 2009 at 11:52 AM, joson yu <yuqianguo@gmail.com> wrote:
>
>> Is there anymethod to get the sql string in the config file which will run
>> when called.
>> in my system,i need to record the sql string as log infomation,is there
>> anyway.
>>
>> Notice,i know how to print the sql with log4j.   but i don't have any idea
>> to use it.
>>
>
>
> --
> Best Regards,
>
> Alin
>
>

Mime
View raw message