NHibernate Envers might be what you're looking for. However - there the audit 
data will be put in seperate tables.
https://bitbucket.org/RogerKratz/nhibernate.envers

________________________________________
Från: [email protected] [[email protected]] för Peter Morris 
[[email protected]]
Skickat: den 19 mars 2012 17:13
Till: nhusers
Ämne: [nhusers] Data versioning

Another OPF I have used allows me to specify that a class is
versioned.  When it is versioned you end up with two additional
columns in each relevant class - TimeStampStart, TimeStampEnd.  When a
new row is inserted you get a TimeStampStart and a null TimeStampEnd.
When an object is modified the existing row has its TimeStampEnd set,
and a new row is inserted with TimeStampStart set.  When a row is
deleted the TimeStampEnd is set on the most recent row.  This means I
must set my primary key to ID + TimeStampStart in order to ensure
uniqueness, and it prohibits me from using foreign key constraints -
but the OPF checks for existence during a DB update.

I'm wondering if NHibernate is flexible enough to make it possible to
extend it in a similar way?  I do enjoy being able to effectively
browse the DB at a specific date/time and see how the data looked at
that point without having to write any code.



--
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en.

Reply via email to