title: JPA 2 : Implicit column reference in the @MapsId mapping fails
body: <p>i am try to use Multiple Mapped Attributes . but when i try to run the code , the code will generate the exception, this example is based on Pro JPA 2 , Chapter 10 book . there is following code : </p>
  
  <p><strong>DeptID.java</strong></p>
  
  <pre><code>public class DeptId implements Serializable{
  
  private static final long serialVersionUID = 5177373337405448966L;
  private int number;
  private String country;
      .....................
  </code></pre>
  
  <p><strong>ProjectId.java</strong></p>
  
  <pre><code>public class ProjectId implements Serializable{
  
  private static final long serialVersionUID = 4239980609226293562L;
  private String name;
  private DeptId deptId;
  .....................
  </code></pre>
  
  <p><strong>Department.java</strong></p>
  
  <pre><code>@Entity
  @IdClass(DeptId.class)
  public class Department implements Serializable {
  
  private static final long serialVersionUID = 1L;
  @Id
  private int number;
  @Id
  private String country;
  private String name;
  
  @OneToMany(mappedBy="deptId")
  List&lt;Project&gt; projects;
      ......................
  </code></pre>
  
  <p><strong>Project.java</strong></p>
  
  <pre><code>@Entity
  @IdClass(ProjectId.class)
  public class Project implements Serializable {
  
  private static final long serialVersionUID = 1L;
  @Id
  private String name;
  
  @Id
  @ManyToOne
  @JoinColumn(name="dept_id")
  private Department deptId;
      ........................
  </code></pre>
  
  <p>this code will generate the follwoing exception </p>
  
  <pre><code>Caused by: org.hibernate.AnnotationException: Implicit column reference in the @MapsId mapping fails, try to use explicit referenceColumnNames: example.domain.Department
  </code></pre>