hibernate报错:JoinColumn cannot be resolved to a type

@ManyToMany(cascade = CascadeType.PERSIST, fetch = FetchType.LAZY)
    @JoinTable(name ="course",
    joinColumns = {@JoinColumn(name = "preplan_sn", referencedColumnName = "preplan_sn")},
    inverseJoinColumns = {@JoinColumn(name = "domain_sn", referencedColumnName ="domain_sn")})

这里需要导入一个包的 
import javax.persistence.JoinColumn; 
但是他不提示要导入这个是要手动导入的。

转载于:https://www.cnblogs.com/zyk2019/p/11315614.html

你可能感兴趣的:(hibernate报错:JoinColumn cannot be resolved to a type)