Search code examples
phpmysqldatabaseintellij-ideaphpstorm

How do I set up a database on PhpStorm?


I am in the process of setting up my development environment and I just need to set up the MySQL Database. I have a .sql file and I'd like to import the information from that into a local database in PhpStorm.

I have the .sql file in my main project folder and I dragged it over to the Database Tool Window and it showed up as a DDL.

My question is: How do I turn that into an actual database that I can run off of localhost?

This is what I see

enter image description here


Solution

  • There is no database in PhpStorm. You need to set up a local server and THEN connect PhpStorm to that database.

    If you are a beginner on Windows then you cannot go wrong with XAMPP.

    PhpStorm can read the DDL but cannot store any data.

    Hope that helps.