Hello everyone
i am using Net Beans for servlet programming.And i am using Oracle for database connectivity.
connection is successful but when i run the code,it show a error as blow:
java.sql.SQLException: [Oracle][ODBC][Ora]ORA-01017: invalid username/password; log on denied
according to me my user name and password are correct,so please give your suggestion
Gursewak Singh wrote:according to me my user name and password are correct
Well, the database disagrees with you...
Are you sure they are correct? Can you connect with the same username and password using the database administration tools that you got with your database? Are you sure you are connecting to the right server, and not some other server?
The database driver says your user ID and password are wrong. You say they are right. So in this case you are wrong.
Of course you might be wrong because you're not connecting to the database you meant to connect to, or for other reasons. But just saying "I'm right" isn't a productive approach to getting your code working.
Sir i can log in using my user name and password when i start working with it.
but during connectivity it cause problem.
i am agree with you that i can wrong. but where???
that is the question.
Now
please tell me if your connection is successful then how to work with it
Connection con = DriverManager.getConnection("jdbc:odbc:system");