i created a new user with all the privileges in mysql and it didn't work. no user works except "root with no password" which is why i created several user and tried it...still didn't work....if anyone know what is wrong....please lemme know....

thank you....

Recommended Answers

All 6 Replies

What does the error message say?

It depends on your error message
if its says access denied then it the problem with mysql /username/password
but if its saying can't reach mysql server its the connectivity problem

mysql can disable access by host aswell as username/password

eg. user@localhost may work, but user@169.1.1.1 wont.

GRANT ALL ON mydb.* TO 'someuser'@'somehost';

will allow all hosts

GRANT ALL ON mydb.* TO 'someuser'@'%';

Thanks for the reply.

I did:

GRANT ALL ON mydb.* TO 'username'@'localhost';

but there is a password in this user thats y it probably it gives an error. "couldn't find the field in table users."

and for reference the error it shows in my web app is:

Warning: mysqli::mysqli() [mysqli.mysqli]: (28000/1045): Access denied for user 'username'@'localhost' (using password: YES)

and works perfectly fine if i use root with no password.

sorry. my bad. that wouldnt have put a password on the user,

GRANT ALL PRIVILEGES ON mydb.* TO 'username'@'localhost' IDENTIFIED BY 'some_pass';

i advise setting a root password. major security risk.

edit:
http://dev.mysql.com/doc/refman/5.1/en/adding-users.html

heh; yeah like what happened with david mckinnons and the U.S Miltary.

i don't get it....phpMyAdmin shows an error...

#1133 - Can't find any matching row in the user table

when i entered:

GRANT ALL PRIVILEGES ON mydb.* TO 'username'@'localhost' IDENTIFIED BY 'password';

i have checked it at-least 20 times if i was making a mistake somewhere....but i cant seem to find any....i'm doing exactly what you're saying....how can it not find that field when i can see it...

and when i made this user i did grant all the privileges if thats what the above command is for.

and thanks for the password on root tip....i do have a password now....thanks....

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.