At 20:05 -0700 8/28/02, neal wrote:
>Alright ... I figured it out (sort of)...
>When I created a user account I put the value '%' in the host field of the
>mysql.user table. I was following the example of the root account that was
>already specified in the table. Apparently if I make that if I change that
>'%' to 'localhost' its fine.
This indicates that when you specified no password, you were being
as the anonymous user in the user table that has a Host value of localhost
and a User value of ''. That's a more specific entry than % + bob.
Once you change your acount from % + bob to localhost + bob, it matches
your connection attempt and then you get connected as bob, not as
the anonymous user.
>I don't really understand why but it fixed it...
Read the section in the MySQL manual that describes how MySQL sorts
user table entries when it compares them to incoming connection attempts.
>From: neal [mailto:nealcabage@stripped]
>Sent: Wednesday, August 28, 2002 7:28 PM
>Subject: JDBC - Access denied (using password: yes)
>Does anyone know why I would recieve this error, when attmepting to connect
>to mySQL via JDBC(driver=Connector/J 3.0 beta) I can connect if I provide no
>password (even if the account specifies a pwd)? I can connect correctly
>using MySQL Front ... but JDBC is giving me this error.
>javax.servlet.ServletException: Invalid authorization specification: Access
>denied for user: 'bob@stripped' (Using password: YES)