数据库系列--postgreSQL序列与id自增长
一、问题背景 将entity实体对象使用JPA持久化persist到数据库时,需要设置id的自增长方式。代码片段如下: (postgreSQL9.9.5)@Id @SequenceGenerator(name = "engine_info_seq", sequenceName = "engine_info_id_seq", allocationSize = 1) @Gen
原创
2017-06-25 13:57:42 ·
13515 阅读 ·
0 评论