Search code examples
javagoogle-app-enginejdodatanucleus

Is there any way to update using a transient object in JDO?


When using an object in transient state and updating in Google App Engine Datastore, it's update operation works perfectly, but when using the same object to update it in MySQL, it is creating a new object as the state is transient.

So I wanted to ask, is there any way to update a data when the state is transient?

I am using Datanucleus JDO and Google App Engine, java ,stripes.


Solution

  • No. It is TRANSIENT, as opposed to DETACHED. You could copy the fields across to a MANAGED object if you really wanted to. But then the whole point of DETACHED state is that you will be modifying it and then ATTACHING it, unlike a TRANSIENT