Why is my Hibernate Query returning stale data?

前端 未结 2 2068
萌比男神i
萌比男神i 2021-02-10 21:55

Quick Version

Basically, I\'m updating a Hibernate Table and subsequent queries are loading a stale value.

Detailed Version

2条回答
  •  无人及你
    2021-02-10 22:55

    After CwmService.get().flushChanges(); // commits the transaction do an explicit commit. flush() only flushes the changes to db but does not commit it. I am not sure about flushChanges() though.

提交回复
热议问题