Magento Forum

SQLSTATE[42000] [1044] Access denied
 
Theo
Jr. Member
 
Avatar
Total Posts:  3
Joined:  2007-12-20
 

I’ve been through the following stages

Created mySQL database
Created database user
Uploaded magento-0.7.15480.tar.bz2 to my webspace
unpacked the files
navigated to installer
Automatic download - Beta
- downloads ok, no errors

Then when attempting the next stage Ive used:

- Host: localhost
and the name of the database, and database user and pw I created earlier.

I then get the following error message:

o SQLSTATE[42000] [1044] Access denied for user ‘xxxxxx_magneto’@’localhost’ to database ‘xxxxxx_magento’
o Database connection error

I’m using:
Apache version 1.3.41 (Unix)
PHP version 5.2.5
MySQL version 4.1.22-standard

Have checked with my web hosts that I’ve correctly specified host, database and user names.

What am I doing wrong?

Thanks for any suggestions

Theo

 
Magento Community Magento Community
Magento Community
Magento Community
 
Theo
Jr. Member
 
Avatar
Total Posts:  3
Joined:  2007-12-20
 

Still no further with this. 

Have deleted all the files, created a new db, created a new user, uploaded the newest release 0.8.16100

Checked with my web host

Still getting the same error message

help please anyone?

 
Magento Community Magento Community
Magento Community
Magento Community
 
SimpleHelixcom
Enthusiast
 
Avatar
Total Posts:  906
Joined:  2007-08-31
Huntsville, AL
 

Are you sure you used the correct mysql host, user, password?

That looks like its the only reason for that error.

Try installing some other apps like osc with the same specified db settings and see if that works.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Theo
Jr. Member
 
Avatar
Total Posts:  3
Joined:  2007-12-20
 

Thanks.

I created a new user and it worked fine.

User error I suppose!

 
Magento Community Magento Community
Magento Community
Magento Community
 
MaxReality
Jr. Member
 
Avatar
Total Posts:  1
Joined:  2008-03-30
 

Spent half a day trying to suss this one. Basically found that when using a shared host when you create the database e.g. magento it gets changed to in my case to e.g. web40-magento-1 So basically when entering the database and username on the installation rather than use magento, you need to use web40-magento-1 (or whatever your host changes the name too). It worked fine doing this. Just to add, the next issue i got on the next screen was a syntax/database permissions error. Just refresh the screen, and that fixes that problem. smile

 
Magento Community Magento Community
Magento Community
Magento Community
 
rlevin1792
Member
 
Total Posts:  31
Joined:  2008-12-08
 

How do you find out what the database name was changed to, and how do you fix the file?

 
Magento Community Magento Community
Magento Community
Magento Community
 
partscash
Member
 
Total Posts:  38
Joined:  2009-09-11
Indiana
 

I had this same problem and then I noticed all I had wrong was the spelling of the database.  What an easy fix.

 
Magento Community Magento Community
Magento Community
Magento Community
 
weatherfront
Jr. Member
 
Total Posts:  30
Joined:  2009-10-07
 

I have VS on an Ubuntu box and get the same problem.

I can only have one db with one user per account.

It works fine for 1.3 but not for 1.4.

The db is OK and I can connect to it with Joomla or my MySQL manager but Magento will not connect to to install.

 
Magento Community Magento Community
Magento Community
Magento Community
 
youngcow
Jr. Member
 
Avatar
Total Posts:  10
Joined:  2008-02-14
 

On hosts such as hostgator (cPanel) you will need to specifically add the mysql user you create to the database, this will allow you to set the required mysql database permissions. (Add User To Database)

Once you have set and saved the mysql permissions / privileges this should solve the problem if it is down to mysql permissions.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Usman Raja
Jr. Member
 
Total Posts:  2
Joined:  2013-01-31
Birmingham
 

actually i am having same error after spending a day on it and a Long while of Googling, i found a solution. i don’t know whether this work for you or not but at my end it is working perfectly fine, i found that adding the following to the exported SQL-file at the very top:

SET SQL_MODE=”NO_AUTO_VALUE_ON_ZERO”;
SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT;
SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS;
SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION;
SET NAMES utf8;
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKSUNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKSFOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODESQL_MODE=’NO_AUTO_VALUE_ON_ZERO’;
SET @OLD_SQL_NOTES=@@SQL_NOTESSQL_NOTES=0;

and at the very end of Sql

SET SQL_MODE=@OLD_SQL_MODE;
SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS;
SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS;
SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT;
SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS;
SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION;
SET SQL_NOTES=@OLD_SQL_NOTES;

Regards
smile

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top