getJdbcTemplate().batchUpdate的性能优化
时间:2016-03-09 19:11:56
收藏:0
阅读:672
执行getJdbcTemplate().batchUpdate需要在ServiceImpl类中添加事务注解(@Transactional(rollbackFor=Exception.class))
@Transactional(rollbackFor=Exception.class) public void updateMenu(String[] objs) throws Exception { repository.updateSomething(objs);//这里调用了批处理 }
原文:http://lipeng1207.blog.51cto.com/1388975/1749183
评论(0)