Database Tools and SQL
Enable the Database Tools and SQL plugin
This functionality relies on the Database Tools and SQL plugin, which is bundled and enabled in IntelliJ IDEA by default. If the relevant features are not available, make sure that you did not disable the plugin.
Press Ctrl+Alt+S to open settings and then select .
Open the Installed tab, find the Database Tools and SQL plugin, and select the checkbox next to the plugin name.
The database management functionality in IntelliJ IDEA is supported by the Database Tools and SQL plugin. The plugin provides support for all the features that are available in DataGrip, the standalone database management environment for developers. With the plugin, you can query, create and manage databases. Databases can work locally, on a server, or in the cloud. The plugin supports MySQL, PostgreSQL, Microsoft SQL Server, SQLite, MariaDB, Oracle, Apache Cassandra, and others. See the full list of supported vendors in Create a data source.
Get started with database tools
These topics are focused on describing features, functionality, the application interface, and might help you to get started quickly.
Learn the main concepts. | |
Start working with your database by creating a connection configuration for it. | |
Connect an SQL file to a data source and run your code. | |
Connect an SQL file to a data source and run your code. | |
View and edit data in data editor. | |
Import and export your data to and from various formats with or without special tools like mysqldump, pg_dump, pg_restore, or psql. | |
Generate diagrams for database objects, build query and execution plans, generate flame graphs for | |
Connectivity issue is a very common definition and might include many problems. This troubleshooting article will guide you through the most common steps to identify and fix the issue. If you could not find the answer, try to contact JetBrains and we can try to help you. |
IntelliJ IDEA Ultimate subscription features
Database functionality support is limited in IntelliJ IDEA without the Ultimate subscription which includes the following features:
- Query execution
Run your queries in query files, scratch files, and general SQL files stored on your machine.
- Explain plan
Build query execution plans for your queries.
- Data editor and viewer
Data editor provides an interface for viewing and working with database object data and query result sets. Also, it allows visualizing data with charts.
Editing DSV files as tables feature is available within the limited functionality.
- Schema comparison and migration
Compare two database objects of the same type and to migrate structure and changes from one object to another.
- Data comparison
Compare data of database tables, views, and materialized views.
- Export and import
Database objects structure and data exporting and importing. This functionality includes data extractor and data loader scripts that are used for copying, exporting, importing, and viewing data in various formats.
Editing DSV files as tables feature is available within the limited functionality.
- Database objects managing
Create and modify
New database objects can be created and the existing ones modified using the Create and Modify dialogs.
Object actions
Various operations on database objects can be performed using the actions from the Object Actions action group of the Database tool window context menu. For example, Drop Primary Key, Truncate, and so on.
- Database diagrams
Visualize database structure, explore, and save the generated diagrams using the database diagrams functionality.
- SQL scripts
Use various scripts from the SQL Scripts action group of the Database tool window context menu.
The Request and Copy Original DDL action remains available within the limited functionality.
- Debug
Debug your Oracle PL/SQL code using the debug functionality.