title: Is it mandatory to have auto increment property for table in mysql even if we set autoincrement in hibernate
body: <p>I am getting the error like <strong>id does not have default value</strong>.In hibernate I used as follows</p>
  
  <pre><code>@Id
  @GeneratedValue(strategy=GenerationType.AUTO)
  @Setter
  @Getter
  @Column(name="id")
  private Long id;
  </code></pre>
  
  <p>But I didn't set auto increment for id in database side.Is it mandatory to set db side also.As per my knowledge hibernate can generate and set the value.</p>
  
  <p>What might be the reason?Thanks in advance...</p>