title: Hibernate with mariaDB generate Key in Mapping Table
body: <p>Hi need some guidance and help on MariaDB with Hibernate,I have many to many mapping between two different tables but while starting server hibernate generates Primary key Instead Of Unique Key don't know why ? is there any dialect problem? Entity is like this.</p>
  
  <pre><code>@ManyToMany(fetch = FetchType.LAZY,cascade=CascadeType.REFRESH)
  @JoinTable(name = "step_childpage", 
  joinColumns = @JoinColumn(name = "step_id"), 
  inverseJoinColumns = @JoinColumn(name = "childpage_id"),
  uniqueConstraints= {@UniqueConstraint(name="UK_step_childpage",columnNames= {"childpage_id","step_id"})},
  foreignKey=@ForeignKey(name="FK_step_childpage_step_id"),
  inverseForeignKey=@ForeignKey(name="FK_step_childpage_page_id")
  )
  public Set&lt;BotPage&gt; getChildPages() {
      return childPages;
  }
  public void setChildPages(Set&lt;BotPage&gt; childPages) {
      this.childPages = childPages;
  }
  </code></pre>
  
  <p>and though i have manually written table hibernate alters while server start-up.
  modified table is like this.</p>
  
  <pre><code>CREATE TABLE `page_childstep` (
      `page_id` BIGINT(20) NOT NULL,
      `childstep_id` BIGINT(20) NOT NULL,
      PRIMARY KEY (`childstep_id`, `page_id`),
      INDEX `FK_page_childstep_page_id` (`page_id`),
      CONSTRAINT `FK_page_childstep_page_id` FOREIGN KEY (`page_id`) REFERENCES `page` (`id`),
      CONSTRAINT `FK_page_childstep_step_id` FOREIGN KEY (`childstep_id`) REFERENCES `teststep` (`id`)
  )
  COLLATE='utf8_general_ci'
  ENGINE=InnoDB
  </code></pre>