Sharing databases between projects in Intellij

I use Intellij to check databases, run sql, view data in tables, etc. It all works fine, but the only thing I miss is the ability to define these data sources once and view them in all my projects, that is, I can share them between other projects and do not need to redefine them for new projects. Is this possible in Intellij?

+18
source share
4 answers

In the properties of the data source, select the data source and click the Make Global button (field with a green arrow). Now you can use the data source from all your projects. However, the data source is no longer stored in the project files, so any other developers working on the same projects will need to define their own data source.

+43
source

The Make Global button is no longer green (Intellij Ultimate 2018.02).

It is located above the list of data sources, as in the (crappy) screenshot.

enter image description here

+10
source

So, as I did in 2018.3, it go to the database tool window, then right-click on the data source that you want to copy, then Database Tools → Copy data source to clipboard. In the database window for the project that you want to copy, click + in the upper left corner and it has the option to import from the clipboard.

0
source

In IntelliJ 2019.1, 2019.2 for sharing a database connection with multiple projects:

  1. Open database panel
  2. Data Source Properties
  3. Make global
0
source

Source: https://habr.com/ru/post/1263574/


All Articles