- 博客(4)
- 收藏
- 关注
原创 hibernate联合主键的创建方式
总结个hibernate联合主键的创建方式,刚看完兵爷的视频,赶紧弄下来。冬爷,赶紧膜拜知道不?我这弄下来是为了明天面试,压力大很知道不? 联合主键,讲一张表中两个属性同时作为主键。 student.java [code="java"]import javax.persistence.EmbeddedId; import javax.persistence.Entity; impor...
2013-07-23 13:43:13
147
原创 spring支持的DAO操作
spring提供访问数据库的有三种方式: HibernateDaoSupport,HibernateTemplate(推荐使用),jdbcTemplate HibernateTemplate:org.springframework.orm.hibernate3.HibernateTemplate HibernateDaoSupport:org.springframework.orm.h...
2013-07-22 00:51:50
96
原创 转载 rollback
转载自 WYhack //注解方式声明事务,该事务声明的范围是service中的方法,而一般的事务声明时不是声明在//业务逻辑方法上的,而是声明在单一的数据库操作方法上的 @Transactional public class UserServiceImpl implements UserService{ private JdbcTemplate jdbcTemplate;...
2013-07-17 22:12:12
90
原创 随记常用SQL(基于oracle)
1. Alter user scott account unlock; this is the command line to unlock the user. 2. Varchar2 support interionalization. 3. NUMBER 7 digits, 2 decimal digits. 4. Dual is the default table to do the ...
2013-07-15 12:22:06
94
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人