hibernate注解使用
今天写了个po类,无论怎么运行环境,都产生不了表,后来才知道是关键字的问题。
public RasDescPo findById(String id) { if (StringUtils.isEmpty(id)) { return null; } List<RasDescPo> rasDescPos = getHibernateTemplate().find("from RasDescPo where RasDescPo.id=?", id); if (CollectionUtils.isEmpty(rasDescPos)) { return null; } return rasDescPos.get(0); }?可以解决问题。