Results 1 to 2 of 2

Thread: Access denied

  1. #1
    Join Date
    Apr 2003
    Posts
    1

    Unanswered: Access denied

    I am having trouble connecting to MySQL using Connector/J 3.0. I have set up
    a root user and password with host specified as localhost, and also a super
    user and password with host specified as %. I can log into both of these
    accounts with no trouble using mysql.

    In my program, however, when I try to connect to MySQL as root with the
    following url:

    jdbc:mysql://localhost/mysql

    I recieve this error:

    java.sql.SQLException: Invalid authorization specification: Access denied
    for user: 'root@127.0.0.1' (Using password: YES)at ...

    Yet when I use the same url to access the database as the super user I can
    connect with no problems. I have a feeling that this is connected to the
    host specified for each user, but I do not see why the root user is being
    rejected as the MySQL database is being hosted on the local machine.

    Any help or advice would be greatly appreciated.

    Using Mandrake 8.1, MySQL 4.0.12, jdk 1.4.1 02, Connector/J 3.0


    Thanks,

    Richard.

  2. #2
    Join Date
    Feb 2002
    Posts
    20
    Richard,

    I had a problem connecting to my remote server this morning using the MySQL Front client. And, although my problem was not the same as yours I did find help here:

    http://www.mysql.com/doc/en/Access_denied.html

    I hope this link helps you.

    Piet

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •