We are working with the project using J2EE Tools including EJB, Servlets, Java Beans, JSP, developed on MVC Framework. MySQL as databse and JBoss Eclipse IDE and JBoss as application server.
We are getting problem with changing the password. It successfully changes the password and temporary saves it in to server (memory) but while we execute the query in database to see whether the password has been changed or not, it does not update the database table.
We have entity bean which deals with database and update or insert the data, Java Beans works as mediaters, Servlets as controllers and JSP as Front end. All things work properly but I dont know why it is not updating the table.
Can anybody suggest me what may be the problem ? Thank You.
Wow, not much information to help us pin-point it. But with EJBs there are transactions, maybe you aren't commiting the transactions. Maybe you Entity Bean mapping to the table and database are wrong, maybe the Connection pool, there are many many more possibilities, but based on what you posted, you haven't given us enough info to figure out more.
Are you using CMP or BMP to update data. With CMP it is simple just call the setter method in the component interface to update the data.
First you will have to see if you get the data in your servlet. Then check if the setPassword method is called right. If all this ok then as Mark said oyu will have to see your deployment descriptor where the ejb-to-table mapping is done. In JBoss it is the jbosscmp-jdbc.xml file.