IntelliJ IDEA 14.0.0 Web Help

Configuring a DB Data Source

Configuring a DB data source involves the following general activities:

To specify general DB data source settings

  1. Open the Data Sources and Drivers dialog by doing one of the following:
  2. Specify the name of the data source.
  3. Specify the data source scope (level). From the Scope list, select:
    • Project if the data source should be available only in the current project.
    • IDE if the data source should be available in all of your projects.

To specify JDBC driver files and class

  1. On the Database tab of the Data Sources and Drivers dialog, use the controls under JDBC driver files to specify the JDBC driver files to be used:
    • To download the necessary driver files from the Internet, or to use the driver files associated with a different data source, select the corresponding option from the list.
    • If the corresponding driver files are available locally on your computer, click browseButton (Shift+Enter) and select the driver file location(s) in the dialog that opens.
  2. From the JDBC driver class list, select the necessary driver implementation class. (The list includes all the driver classes detected in the specified driver files.)

To specify the database access settings

  1. In the Database URL field, specify the database URL.
  2. In the User and Password fields, specify your database access credentials.
  3. If, to access the database, you are going to use SSH, click Configure SSH and specify the associated settings in the Configure SSH Tunnel dialog that opens.

To test the connection with the database

  • To make sure that the database connection settings are correct and IntelliJ IDEA can communicate with the target database, click the Test Connection button.

    For IntelliJ IDEA to establish the connection with the database, the corresponding database server must be up and running.

To download the database tables

To get access to specific tables

  1. Open the Schemas & Tables tab of the Data Sources and Drivers dialog box.
  2. Do one of the following:
    • If the target database supports schemas, select the Scan for Tables check box next to the relevant schemas.
    • Specify the pattern of table names to retrieve the matching tables only.

To configure the behaviour of the Database Console

  1. Open the Console tab of the Data Sources and Drivers dialog box.
  2. Specify the SQL dialect to be used by default. Based on this setting, IntelliJ IDEA provides you with code assistance in the Database Console tool window.
  3. Specify the run configuration to launch the Database Console tool window.

To view and edit advanced connection properties

  • In the Advanced tab of the Data Sources and Drivers dialog box, update the contents of the Value text box next to the names of the relevant connection properties.

See Also

Language and Framework-Specific Guidelines:

Web Resources:

Last modified: 12 November 2014
comments powered by Disqus