Access denied for user 'root'@'localhost'

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
konfuzion
User
Posts: 378

Access denied for user 'root'@'localhost'

Post by konfuzion »

C:\Bitnami\wampstack-8.1.9-0\apache2\htdocs\demo2023\vendor\doctrine\dbal\src\Driver\API\MySQL\ExceptionConverter.php(101): An exception occurred in the driver: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO)

Using default demo2023 and click generate, it shows the above error. I think it's because no password is set, but if I enter password and connect to db, the default project table settings will be lost. How to solve this?


mobhar
User
Posts: 11703

Post by mobhar »

Do not click Connect button. Simply click on Tools -> Synchronize.


arbei
User
Posts: 9356

Post by arbei »

You may follow the readme.txt for the demo project:

Change the connection info and save the project if necessary:
- change the connection info in the [Database] tab, click "Tools"->"Synchronize" to update the main database connection info,
- click "Edit"->"Add Linked Tables", select "demo2 (var: demo2, type: MySQL)" from the Database selection list (error may occur because the username and password are incorrect, ignore it),
- click the "Synchronize" button to update the database connection info and then click "OK' to close the form


Dadinos2
User
Posts: 52

Post by Dadinos2 »

Got this same error:

...\vendor\doctrine\dbal\src\Driver\API\MySQL\ExceptionConverter.php(101): An exception occurred in the driver: SQLSTATE[HY000] [1045] Access denied for user 'myusename'@'2a02-a.......fixed6.xxx.net' (using password: YES)

The sync of the tables is working this error occures when I want to login.

Any ideas?

Regards,

Aren


mobhar
User
Posts: 11703

Post by mobhar »

I cannot reproduce the issue.

Which MySQL version are you using?


arbei
User
Posts: 9356

Post by arbei »

Dadinos2 wrote:

Access denied for user 'myusename'@'2a02-a.......fixed6.xxx.net' (using password: YES)

You need to change to correct user name and password for your database.


Dadinos2
User
Posts: 52

Post by Dadinos2 »

Got it working again!

Databaseserver
Server: Localhost via UNIX socket
Servertype: MariaDB
Serverversie: 10.5.17-MariaDB-cll-lve-log - MariaDB Server
Protocolversie: 10
Karakterset van server: cp1252 West European (latin1)

My MySql database is located externally and I had always to whitelist the IP's that want to use it.
Until now the IP adres was a normal IPv4 address.

This error occured because I need to whitelist the IPv6 address also now.

The strange thing is that when I startup the project in PHPmaker it syncs and updates the tables without any problem.
With only the IPv4 address whitelisted. When I start the generated application and login the error occured.

Now with the IPv6 address also whitelisted it runs without problems.

Regards,

Aren


Post Reply