How to Create an ER Diagram in DBeaver

Entity Relationship Diagrams in DBeaver

DBeaver is a desktop database client for managing relational database management systems (RDBMS) including MySQL and PostgreSQL. One of its database development features include the ability to create entity relationship (ER) diagrams. In this tutorial we’ll cover how to create an ER diagram in DBeaver.

Getting Started with the DBeaver Desktop Application

  1. Download the free DBeaver community edition from your Linux/BSD package manager or https://DBeaver.io/download/ with the appropriate DBeaver download link.
  2. Install DBeaver and launch the program.
  3. Decline the sample database. On the next page, choose the type of database system you want to import.

Connect a Database in DBeaver

For remote databases, you’ll need the following: 

  • Server hostname or IP
  • Database name
  • Database (or cPanel) username and username password

You may be prompted to download driver files to complete remote connections.

For locally stored databases, the easiest option to create an ER diagram in DBeaver seems to be to use SQLite. If the database is written in another SQL format (Hive, IBM Db2, etc.), you’ll need to convert the SQL file to SQLite. There are many third party tools available online.

Exercise caution with using any third party software. Don’t hesitate to examine the privacy policy and reputation for a developer before using their product. We do not recommend purchasing SQL conversion software to create ERDs in DBeaver. Instead, you should use a dedicated database client such as MySQL Workbench or phpMyAdmin.

For this DBeaver tutorial we used the free API from RebaseData.com to convert a WordPress MySQL database to SQLite. The zip file included the SQLite file.

curl -F files[][email protected] 'https://www.rebasedata.com/api/v1/convert?outputFormat=mysql&errorResponse=zip' -o output.zip

Create an ER Diagram in DBeaver

After you connect your database(s), you’re ready to create an ER diagram.

  1. In the lower-left corner right-click “ER Diagrams” and select “Create New ER Diagram.”
    Create an ER Diagram in DBeaver
  2. Type a title for your new database ER diagram. This will also be the filename with an “.erd” extension. Select the checkbox for your database to add all tables. Or, select the arrows to expand the database and tables list to add specific tables.
    DBeaver Diagram Create Wizard
  3. Once you’ve decided which tables to add, select “Finish.”
  4. To add any tables to a database relationship diagram, drag and drop them from the Database Navigator sidebar on the left.

There are no one to one or one to many relationships within the default WordPress database.

DBeaver ER Diagram

Edit ER Diagrams

In the ERD window you can do the following:

  • Zoom in and out
  • Rearrange the database diagram
  • Add a grid to more easily align tables
  • Toggle the properties sidebar for a selected table or entity (column)
  • Toggle the outline sidebar
  • Print or export the ERD in GraphML and standard image formats
  • Configure ERD settings
DBeaver Properties for ERD Editor

Get software support for the database diagram tool from the DBeaver GitHub page.

With our Cloud Server Hosting, you can deploy a lightning-fast, reliable cloud platform with built-in redundancy – ensuring the availability of your environment!

InMotion Hosting Contributor
InMotion Hosting Contributor Content Writer

InMotion Hosting contributors are highly knowledgeable individuals who create relevant content on new trends and troubleshooting techniques to help you achieve your online goals!

More Articles by InMotion Hosting

Was this article helpful? Join the conversation!