标识符映射的列数错误:

时间:2017-07-06 15:52:57

标签: spring spring-mvc

任何人都可以帮助我 我有这个错误 由以下原因引起:org.hibernate.MappingException:标识符映射列数错误:com.twins.FootFans.model.MemberAllTeam类型:component [allTeam,member]

@Id
@ManyToOne
@JoinColumn(name = "team_id", referencedColumnName = "teamId")
private Team allTeam;

@Id
@ManyToOne
@JoinColumns({
    @JoinColumn(name = "identifier_AllTeam" ,referencedColumnName ="identifier" ),
    @JoinColumn(name = "connectionType_AllTeam" ,referencedColumnName ="connectionType") 
} )

private Member member;