title: How to generate automatically relationships with JPA with IntelliJ?
body: <p>I found this solution for a problem I have: how to generate entities with JPA annotations from a given database.</p>
  
  <p><a href="https://stackoverflow.com/questions/5259276/intellij-idea-10-generate-entity-pojo-from-db-model">IntelliJ IDEA 10 generate entity (POJO) from DB model</a></p>
  
  <p>Now with IntelliJ I'm given the possibility to <strong>create relationships between entities manually</strong>. Is there a way to generate them <strong>automatically</strong> as it did with entities? 
  I used the <code>REFERENCES</code> keyword when needed while creating the database. I suppose there should be an automatic mapping of relationships as well!</p>