[appengine-java] Re: What is entity "detached yet this operation requires it to be attached?"

2010-09-03 Thread nksi
hi. I came to be able to merge and persist by the addition of the following to persistence.xml. but,in this case, i need to write dirty code(ex: transaction.begin - commit and rollback). When the flag is true, it is mysterious not to be able to do it. And if the value is true, where does transact

[appengine-java] Re: What is entity "detached yet this operation requires it to be attached?"

2010-09-03 Thread Sekhar
I can see why messing with a new entity outside a transaction before persist is an issue if datanucleus.NontransactionalWrite is set to false, but I have both datanucleus.NontransactionalRead and datanucleus.NontransactionalWrite set to true and I still get the error. The puzzling thing is this err

[appengine-java] Re: What is entity "detached yet this operation requires it to be attached?"

2010-09-03 Thread Didier Durand
Hi, This means that you are trying to act on an entity via the Persistence Manager when this same entity is not yet under control of the PM. It usually happens when you do a new on a Class and do not call the persist() function of the PM for that newly created instance before doing what you try t

[appengine-java] Re: What is entity "detached yet this operation requires it to be attached?"

2010-09-02 Thread nksi
I also have a similar problem. in my exsample: @Entity class Test { @Id @Column(name = "ID") @GeneratedValue(strategy = GenerationType.IDENTITY) private Long id; @Column(nullable = false) private Boolean isLatest; } # service Test test = TestDao.getByCode("code") test.setIsLatest(fals

[appengine-java] Re: What is entity "detached yet this operation requires it to be attached?"

2010-07-20 Thread Sekhar
Anyone? Would appreciate just about any help you can give! On Jul 15, 8:45 am, Sekhar wrote: > I pretty frequently get an error for my JPA entities saying an entity > is "is detached yet this operation requires it to be attached" and the > transaction isrolledback: > "com.google.apphosting.utils.