somebody help me to get rid of this problem
dear all,
java.sql.SQLException: Invalid authorization specification: Access denied for user: 'username@127.0.0.1' (Using password: YES)
at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:659)
at com.mysql.jdbc.Connection.createNewIO(Connection.java:1562)
at com.mysql.jdbc.Connection.<init>(Connection.java:491)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:346)
at java.sql.DriverManager.getConnection(DriverManager.java:512)
at java.sql.DriverManager.getConnection(DriverManager.java:171)
at MyThread.run(ServerTelnet.java:208)
at java.lang.Thread.run(Thread.java:536)
i get this error when my java program try to connect to the mysql..
i installed mysql in /usr/bin as i dun know where to install ... i hope the destination folder for installation doesnt matter....
i installed this mysql as root...
i have a user called sara under the root.
i use sun one studio for my java applications .....
this user sara dont have the previliges to access the database..
i referred the mysql documentation, but doesnt help me to sort out .. & itried some commands given by some users in some other threads..
the commands i used to grant access:::
grant select on saravanan.USERS to sara;
flush previliges;
saravanan is the name of the database... USERS is the name of the table which i created under the root account..
grant all privileges on *.* to '@sara'@'%' identified by 'abcd' with grant option;
flush previleges;
the respond i got:
Query OK, 0 rows affected (0.00 sec)
it says 0 rows affected....
how to solve this ?????
can i install mysql again ????? which i feel to be the final solution,,
and if i reinstall the mysql, will there be any conflicts between this mysql & the newer one????
any 1 help me......... this really affects my project work........
i already started another thread but there were no reply after a few posts which dint really helped....
iam a new user & using mandrake linux for past 2 months.... this is my first time in linux....
help plz......
|