Jump to content

Why "Database connection failed"? 


38175425

Recommended Posts

29 minutes ago, requinix said:

Is MySQL running? On port 8889? Is the username and password correct? Does the database exist? Does the user have permission to access it?

Did you look at the exception in $e to see if that might have useful information?

1. Yes. MySQL is running on port 8889.

88888.thumb.png.de34e001b3506bb7bd5e2ffdd22d25ea.png

 

2. Where do I check if the username and password are correct?

3. Yes. The database does exist.

dododo.png.cdff8b205919b1fbd9fd6db8887f8c13.png

 

4. How do I check if the user have permission to it?

 

Link to comment
Share on other sites

9 minutes ago, 38175425 said:

2. Where do I check if the username and password are correct?

Either you or MAMP would have set up that user and its password.

I think that information is available somewhere in phpMyAdmin.

 

9 minutes ago, 38175425 said:

4. How do I check if the user have permission to it?

Try logging into phpMyAdmin with those credentials and seeing what happens.

Link to comment
Share on other sites

18 minutes ago, requinix said:

Either you or MAMP would have set up that user and its password.

I think that information is available somewhere in phpMyAdmin.

 

Try logging into phpMyAdmin with those credentials and seeing what happens.

Yes. The username and the password are correct.

redline.png.81cc93f5f26e47d3c572d04fb194cba9.png

Link to comment
Share on other sites

On 9/18/2021 at 12:36 AM, ginerjm said:

For the benefit of others who may come here with the same problem - how about telling us what your solution was?

I found the problem: the password and the username were incorrect.
I went to MAMP>bin>phpMyAdmin>config.inc and I found the correct password and the correct username

correct.png.e6418fd4d50acbc0c5ca98cc39612843.png

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.