 |
|
 |
 |
|
 |
 |
| Author |
Message |
|
|
Post subject: Update and Save fails to persist changes to the database
Posted: Oct 17, 2008 - 07:52 PM
|
|
Joined: Oct 17, 2008
Posts: 3
|
|
Hi,
I'm using MyEclipse Hibernate and Spring support. I have created my database table, and managed to successfully connect to the database.
Using MyEclipse reverse engineering, MyEclipse created my DAOs, POJOs and mapping files. I am able to retrieve all data from the database (MySQL) using the classes set up by MyEclipse. However, while trying to update or insert any rows into any of the tables the following occurs.
1) MyEclipse DAOs go through without failure.
2) Retrieving by findAll() method gives me updated data
3) Checking the database there are no changes
4) Trying to update this row from MySQL Administrator reports that the row in question is locked.
5) After killing tomcat lock is released and I can now update changes.
This is very difficult for me to debug for two reasons. First, there are no error messages reported, so not much to start from. Two, I'm a newbie to hibernate, that's one of the reasons I use MyEclipse for this project.
Any help on this issue would be highly appreciated.
Thx in advance,
Vedran |
|
|
| |
|
|
|
 |
|
|
Post subject: RE: Update and Save fails to persist changes to the database
Posted: Oct 19, 2008 - 03:27 PM
|
|
Registered Member


Joined: Apr 18, 2007
Posts: 6126
|
|
Vedran,
Make sure you are using transaction management for update and save. That should sort this issue out. |
_________________ Nipun
MyEclipse Support
|
| |
|
|
|
 |
|
|
Post subject: Re: RE: Update and Save fails to persist changes to the data
Posted: Oct 19, 2008 - 03:45 PM
|
|
Joined: Oct 17, 2008
Posts: 3
|
|
| support-nipun wrote: | Vedran,
Make sure you are using transaction management for update and save. That should sort this issue out. |
Nipun,
thank you for your answer. I am working in the same way as it is descibed in MyEclipse Spring Hibernate tutoria (http://www.myeclipseide.com/documentation/quickstarts/hibernateandspring/)l.
Coud you please add a link to a MyEclipse online recource to point me to the right direction? |
|
|
| |
|
|
|
 |
|
|
Post subject: RE: Re: RE: Update and Save fails to persist changes to the
Posted: Oct 19, 2008 - 04:14 PM
|
|
Joined: Oct 17, 2008
Posts: 3
|
|
| I managed to find sufficient resources. Thanks for the correct pointer Nippun. |
|
|
| |
|
|
|
 |
|
|
Post subject: RE: Re: RE: Update and Save fails to persist changes to the
Posted: Oct 20, 2008 - 03:49 PM
|
|
Registered Member


Joined: Apr 18, 2007
Posts: 6126
|
|
| Your welcome. |
_________________ Nipun
MyEclipse Support
|
| |
|
|
|
 |
|
|
| |
|
|
 |
|
 |
|
|
|
 |