2012年5月27日

MyBatis使用MySQL数据库如何在执行insert操作后返回自增的主键

摘要: 数据库:MySQL5表:create table play(iid int(10) not null primary key auto_increment,typeId int(3));Play.java:public class Play{ private Integer iID; private Integer typeID; ...setter and getter省略...}play-mapper.xml:<mapper namespace="PlayDAO"> <resultMap id="BaseResultMap" typ 阅读全文

posted @ 2012-05-27 09:33 izumi 阅读(18658) 评论(1) 推荐(0)

导航