title: Caused by: org.hibernate.AnnotationException: mappedBy reference an unknown target entity property
body: <p>I need to make onetomany relationship but this error appears
  mappedBy reference an unknown target entity property
  this is parent <code>Caused by: org.hibernate.AnnotationException: mappedBy reference an unknown target entity property</code></p>
  
  <pre><code>package com.dating.model;
  import java.util.ArrayList;
  import java.util.Collection;
  import java.util.List;
  import javax.persistence.CascadeType;
  import javax.persistence.Column;
  import javax.persistence.Entity;
  import javax.persistence.FetchType; 
  import javax.persistence.GeneratedValue;
  import javax.persistence.Id;
  import javax.persistence.JoinColumn;
  import javax.persistence.ManyToOne;
  import javax.persistence.OneToMany;
  import javax.persistence.Table;
  import org.hibernate.annotations.GenericGenerator;
  @Entity
  @Table(name="question")
  public class PsyQuestions {
  
      @Id
      @GenericGenerator(name="autoGen" ,strategy="increment")
      @GeneratedValue(generator="autoGen")
      @Column(name="questionid")
      private long psyQuestionId;
      @Column(name="questiontext")
      private String question;
  
      @OneToMany(fetch = FetchType.LAZY,mappedBy="question")
      private List&lt;PsyOptions&gt; productlist=new ArrayList&lt;PsyOptions&gt;();
  
  
      public PsyQuestions() {
          super();
      }
  
      public List&lt;PsyOptions&gt; getProductlist() {
          return productlist;
      }
  
      public void setProductlist(List&lt;PsyOptions&gt; productlist) {
          this.productlist = productlist;
      }
  
      public long getPsyQuestionId() {
          return psyQuestionId;
      }
      public void setPsyQuestionId(long psyQuestionId) {
          this.psyQuestionId = psyQuestionId;
      }
      public String getQuestion() {
          return question;
      }
      public void setQuestion(String question) {
          this.question = question;
      }
  }
  </code></pre>
  
  <p>
  and this child class
  </p>
  
  <pre><code>package com.dating.model;
  import javax.persistence.CascadeType;
  import javax.persistence.Column;
  import javax.persistence.Entity;
  import javax.persistence.FetchType;
  import javax.persistence.GeneratedValue;
  import javax.persistence.Id;
  import javax.persistence.JoinColumn;
  import javax.persistence.ManyToOne;
  import javax.persistence.Table;
  
  import org.hibernate.annotations.GenericGenerator;
  
  @Entity
  @Table(name="option")
  public class PsyOptions {
  
      @Id
      @GenericGenerator(name="autoGen" ,strategy="increment")
      @GeneratedValue(generator="autoGen")
      @Column(name="optionid")
      private long psyOptionId;
      @Column(name="optiontext")
      private String optionText;
  
      @JoinColumn(name = "questionid")
      @ManyToOne(cascade = CascadeType.ALL,fetch = FetchType.LAZY)
      PsyQuestions psyQuestions;  
  
  
      public PsyOptions() {
          super();
      }
  
      public PsyQuestions getPsyQuestions() {
          return psyQuestions;
      }
  
      public void setPsyQuestions(PsyQuestions psyQuestions) {
          this.psyQuestions = psyQuestions;
      }
  
      public long getPsyOptionId() {
          return psyOptionId;
      }
      public void setPsyOptionId(long psyOptionId) {
          this.psyOptionId = psyOptionId;
      }
      public String getOptionText() {
          return optionText;
      }
      public void setOptionText(String optionText) {
          this.optionText = optionText;
      }
  
  }
  </code></pre>