Tool to generate a ERD (entity-relation diagram) based on JPA annotations

Mohammad Moghimi picture Mohammad Moghimi · Apr 17, 2012 · Viewed 16.5k times · Source

I'm writing a java code using ormlite. I was wondering if it's possible to generate an ERD from the JPA annotations in my code. Basically, I need the reverse of this: How can I transform Entity-Based diagram to a JPA java code

Answer

Hollis Waite picture Hollis Waite · Oct 31, 2013

IntelliJ IDEA (Ultimate) provides JPA to ER-Diagram generator.

context menu

In the Persistence tool window, select appropriate node. Then use context menu to select "ER Diagram".

sample ER diagram

Note that JPA facet must be linked to module and UML plugin should be active.