retrieving the generated sql

44 views
Skip to first unread message

Richard Beacroft

unread,
Mar 4, 2012, 8:45:34 AM3/4/12
to mybatisnet-user
Hi,

We are looking to use iBatis to generate complex sql based on a set of
rules. The framework seems to be a good fit for this purpose.

However, it appears that at present, there is no way to retrieve the
sql that "would" be run, without executing it.

This would be useful for not just debugging, but sometimes it is worth
storing the generated sql for later execution.

Any plans to make this available?

Regards,
Rik

丰刘

unread,
Feb 9, 2013, 12:03:58 AM2/9/13
to mybatis...@googlegroups.com
Loogging of iBatis will show the SQL.

App.config/Web.config:
  <configSections>
    <sectionGroup name="iBATIS">
      <section name="logging" type="IBatisNet.Common.Logging.ConfigurationSectionHandler, IBatisNet.Common" />
    </sectionGroup>
    <section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />
  </configSections>
...
And reference IBatisNet.Common.Logging.Log4Net.dll, log4net.dll to your project.


2012/3/4 Richard Beacroft <r_bea...@hotmail.com>



--
Thanks
Liu Feng
Reply all
Reply to author
Forward
0 new messages