![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
ibatis_code_example
yql1986
这个作者很懒,什么都没留下…
展开
-
example of well-written jdbc code
public Employee getEmployee(int id) throws SQLException{ Employee employee=null; String sql="SELECT * FORM EMPLOYEE WHERE EMPLOYEE_NUMBER=?"; Connection conn=null; PreparedStatement ps=null; ResultS转载 2012-07-16 11:57:32 · 445 阅读 · 0 评论 -
Local transaction
public void runStatementsUsingLocalTransactions() { SqlMapClient sqlMapClient=SqlMapClientConfig.getSqlMapClient(); try{ sqlMapClient.startTransaction(); Person p =(Person)sqlMapCl转载 2012-07-16 11:59:37 · 988 阅读 · 0 评论 -
Custom transaction control with setUserTransaction
public void runStatementsUsingSetUserConnection() { SqlMapClient sqlMapClient =SqlMapClientConfig.getSqlMapClient(); Connection conn = null; try { conn = dataSource.getConnection(); conn.setA转载 2012-07-16 12:00:40 · 552 阅读 · 0 评论 -
Custom transaction control with openSession
public void runStatementsUsingSetUserConnection() { SqlMapClient sqlMapClient =SqlMapClientConfig.getSqlMapClient(); Connection conn = null; SqlMapSession session = null; try { conn = dataSo转载 2012-07-16 12:02:23 · 413 阅读 · 0 评论 -
An example of the <sql> and <include> tags
select * from order select count(*) as value from order <![CDATA[ where shipDate > #value:DATE# ]]>转载 2012-07-16 12:05:09 · 411 阅读 · 0 评论