Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » [CDO] get deleted Revision/CDOObject
[CDO] get deleted Revision/CDOObject [message #988986] Tue, 04 December 2012 02:39 Go to next message
Erdal Karaca is currently offline Erdal Karaca
Messages: 701
Registered: July 2009
Senior Member
I guess this is not related to the used store (using hibernate with latest support for auditing), so asking in general:

If I query the CDOCommitHistory, I can traverse the CDOCommitInfos and get the detachedObjects at that commit time.

However, since the list of detached objects consists of CDOIDAndVersions, I dont know how to get the Revision/CDOObject of that CDOIDAndVersion.
Re: [CDO] get deleted Revision/CDOObject [message #988989 is a reply to message #988986] Tue, 04 December 2012 02:48 Go to previous messageGo to next message
Eike Stepper is currently offline Eike Stepper
Messages: 5446
Registered: July 2009
Senior Member
Am 04.12.2012 08:39, schrieb Erdal Karaca:
> I guess this is not related to the used store (using hibernate with latest support for auditing), so asking in general:
>
> If I query the CDOCommitHistory, I can traverse the CDOCommitInfos and get the detachedObjects at that commit time.
>
> However, since the list of detached objects consists of CDOIDAndVersions, I dont know how to get the
> Revision/CDOObject of that CDOIDAndVersion.
That's not possible because these objects have been deleted. If you're asking how to access the objects at the time
before they've been deleted, you can query them through the revision manager by specifying a timestamp that's one
millisecond less than the CDOCommitInfo timestamp. You could also open an audit view at that time.

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: [CDO] get deleted Revision/CDOObject [message #988993 is a reply to message #988989] Tue, 04 December 2012 03:10 Go to previous message
Erdal Karaca is currently offline Erdal Karaca
Messages: 701
Registered: July 2009
Senior Member
Thanks, that makes sense!

Eike Stepper wrote on Tue, 04 December 2012 08:48
Am 04.12.2012 08:39, schrieb Erdal Karaca:
> I guess this is not related to the used store (using hibernate with latest support for auditing), so asking in general:
>
> If I query the CDOCommitHistory, I can traverse the CDOCommitInfos and get the detachedObjects at that commit time.
>
> However, since the list of detached objects consists of CDOIDAndVersions, I dont know how to get the
> Revision/CDOObject of that CDOIDAndVersion.
That's not possible because these objects have been deleted. If you're asking how to access the objects at the time
before they've been deleted, you can query them through the revision manager by specifying a timestamp that's one
millisecond less than the CDOCommitInfo timestamp. You could also open an audit view at that time.

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper

Previous Topic:Filter notifications when resource is loading
Next Topic:[CDO] OCL Query to sql
Goto Forum:
  


Current Time: Wed Apr 16 20:55:42 EDT 2014

Powered by FUDForum. Page generated in 0.01635 seconds