How to configure DB Navigator for Jetbrains PHPStorm and WebStorm

36,799

Solution 1

Instructions

  1. Install DB Navigator Plugin via menubar >> Settings >> Plugins >> Available-Tab
  2. Download MySQL jdbc connector from here >> http://www.mysql.com/downloads/connector/j/
  3. Unpack MySQL jdbc connector to a directory of your choice
  4. Restart PHPStorm / WebStorm
  5. Add a DB via menubar >> DB Navigator >> Settings >> Connection-Tab >> Plus-Button
  6. Enter the parameters for your connection (see below for possible entries for a local MySQL DB)

Possible parameters for a local MySQL DB

  • Name: name of choice (localhost)
  • Description: additional info of choice (dbname)
  • Driver Library: path to the .jar file (that is the directory used in step 3)
  • Driver: preferred driver (most likely the standard driver will do >> com.mysql.jdbc.Driver)
  • URL: connection URL with a jdbc reference (e.g.: jdbc:mysql://localhost:3306/)
  • UserName: db username of choice (root)
  • Password: db password of choice (root)

Solution 2

Just make sure you added jdbc:mysql:// before hostname. That solved my problem.

jdbc:mysql://my-db-url.com

Solution 3

First of all, you don't need to install third-party DB Navigator plug-in, as database functionality is available in PhpStorm out of the box, see Tools | Data Sources.

Add new data source, it will allow to choose the database and the driver, and will download the required database drivers automatically.

Share:
36,799
R01010010
Author by

R01010010

I'm trying to improve the web application world.

Updated on January 09, 2020

Comments

  • R01010010
    R01010010 over 4 years

    I need to set up a connection in the DB Navigator plugin for PHPStorm in a mac (snow leopard). It asks me for the route of a library that implements the java.sql.Driver class. I just don't have any idea of where is it. Any advice?

  • R01010010
    R01010010 over 12 years
    Thank you i found it and although i don't see the databases to explore at least i made the conection. Thank you again, i'll take a look.
  • Jeff Hines
    Jeff Hines over 11 years
    I had some trouble getting this figured out until I realized that my server is not listening on any sockets that could be reached from the outside internet.
  • Sizzling Code
    Sizzling Code about 11 years
    i lost you from step 4, i installed db navigator from plugins, but how to open, i mean from where to open, any shortcut for it?
  • Rocco
    Rocco about 11 years
    @SyedHaiderHassan after you installed DB Navigator plugin & restart PHPStorm, there should be a menu DB Navigator between Window and Help on the menubar
  • Bruiser
    Bruiser almost 11 years
    @Rocoo: Thanks, restarting the program has been added as step 4 of the instructions
  • Simon Bengtsson
    Simon Bengtsson about 10 years
    Using Oracle JDBC driver I don't get any options at all in the select driver dropdown. Anyone had the same problem?
  • Erik
    Erik about 10 years
    for SQLite do most PHPStorm users just run the Firefox plugins to read them? Does PHPStorm have a SQLite compatible DBNavigator?
  • Pete Mancini
    Pete Mancini over 9 years
    Thanks, that answer just helped me a lot. Thanks for contributing it Bruiser.
  • tozlu
    tozlu about 9 years
    This also solves the "driver refused to create connection for this configuration. no failure information provided" error.