Im trying to connect to the database using DB navigator in phpDesigner.
I can already connect to my database with php and PDO using localhost as the host and the username and password setup through PHPmyadmin. I dont understand why that works since my database is stored on Digital Oceans VPS but it works, i can write to and from the database no problem and access my database at www.mywebsite/phpadmin
normally when localhosts works it means i have LAMP installed on my local machine but i dont and when i worked previously with shared hosting for another site the host was the ip address.
Anyway i didnt worry about it but now im trying to use DB navigator with PHPstorm and it needs to setup the database connection. since im using the same username and password that works for php connection to the database i assume that is correct.
I have installed the driver library and selected the .com.mysql.jdbc.Driver as the driver. for URL which i assume must be host i have tried the following:
pretend droplet ip = 123.456.789 jdbc:mysql://localhost:3306 jdbc:mysql://123.456.789:3306 jdbc:mysql://mywebsite.com:3306 jdbc:mysql://www.mywebsite.com:3306
None of these work and all say no packets recieved. Anyone know what the correct connection string is?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.
Click below to sign up and get $100 of credit to try our products over 60 days!