实体类中一个属性和数据库列名不一致 (
class user{
private String password;
@Column(name = "securityCode")
public String getPassword() {)
}
我写了一个hql 比如:from user where password="123"(这个我知道) 但是from user where securityCode="123"
为什么也能正常查询。求解释,
...全文
36013打赏收藏
hql查询问题:都来看看 这个怎么解释。
实体类中一个属性和数据库列名不一致 ( class user{ private String password; @Column(name = "securityCode") public String getPassword() {) } 我写了一个hql 比如:from user where password="123"(这个我知道) 但是from user where securityCode="123" 为什么也能正常查询。求解释,