I have set an attribute named USER, whose values are retrieved through a html, depending upon the user. In this jsp i need to change the password. 't1','t2','t3' are getting old password, new password & confirm password field from html.
First i am checking whether old password field and password column in database has same value.
For updating the password i am retrieving ID no also from the table. (My all tables has ID,username, and password column)
But, while retrieving ID , its showing the error, "Invalid column name". Even the index number (instead of "ID") is not working and showing the error "INVALID COLUMN NUMBER"
1. Your SELECT says : "select password". You're not getting any ID here. Did you want to do something like "select id, password..." ?
2. Are you sure that the name of the table is set in a session attribute called "user" ??
Yes , i am not getting any ID here. I am just checking for same password, If it is found, then i am getting the ID.
Yes, i am sure that the name of the table is set in a session attribute called "user".