This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
hi everyone, Please help me out.I have a jsp page where the username and password is validated and in the main page there is a link to change password .the user changes the password and the master table is also updated with the new password so that the user logs in with the new password.The problem is that the new password is been put in upper case,and it is updated in the master table but when i log in using the new password and enter the same in lower case letters, than also it is allowing me to enter into the next page.this should not happen.that means it is not validating properly with the database or else it is not checking for case-sensitive. please suggest me with a solution. thanks in advance.
that means it is not validating properly with the database or else it is not checking for case-sensitive.
First you need to isolate the exact problem and decide among the two. What happens if the password is incorrect ? And which method are you using to compare the passwords? The equals() method of string class is by default case sensitive.