[google-appengine] Re: Update an Existing object in the datastore - Problem

2011-01-01 Thread lisandro
Hi Stevko! -unTorneo.getEquiposTorneo() , return a collectionList of objects Equipo. -unTorneo is retrieved by pm.getObjectById(MyObject.class, myId );. The problem is that sometimes he persists and sometimes he does not persist. I hope that it uses as help and could help me... Thanks. Happy

Re: [google-appengine] Re: Update an Existing object in the datastore - Problem

2010-12-31 Thread A. Stevko
Hello Lisandro, What I don't see is how you are retrieving the persisted object from the database. What does unTorneo.getEquiposTorneo() do? Using JDO, I'm used to working with a PersistenceManager object and writing transactions with a template like this... // inject the PersistenceManager

[google-appengine] Re: Update an Existing object in the datastore - Problem

2010-12-30 Thread lisandro
Hi! Ikai, I have tried but it me did not work: I have tried but it me did not work. The modified code: tx.begin(); JDOHelper.makeDirty(unTorneo.getEquiposTorneo(), equiposTorneo); ListEquipolistEquipos = unTorneo.getEquiposTorneo();

[google-appengine] Re: Update an Existing object in the datastore - Problem

2010-12-30 Thread lisandro
I have tried also: tx.begin(); ListEquipolistEquipos = new ArrayListEquipo(); listEquipos=unTorneo.getEquiposTorneo(); unTorneo.setEquiposTorneo(listEquipos); unTorneo.agregarEquipo(unEquipo); //pm is