
ibatis
文章平均质量分 81
tianshi1017
这个作者很懒,什么都没留下…
展开
-
ibatis 返回list<String[]>----resultClass="hashMap" 可以实现
select a.id as id, count(distinct b.id) as bid, count(distinct c.id) as cid from user a left join user_role b on a.userId = b.userId left join原创 2012-06-19 17:33:02 · 7766 阅读 · 0 评论 -
ibatis 取值以及sql注入
ibatis 配置文件中取值有两种:#和$如果传值为userName="zhangsan"#userName# , ibatis会自动在它的外面加上引号,结果是这样的:select * from user where user_name = 'zhangsan' ;$userName$ 则是把zhangsan作为字符串拼接到sql中,结果是这样的:select * from user原创 2013-02-22 11:09:54 · 1197 阅读 · 0 评论