Question

We wanted to use Append-Only database model (no update/delete only insert). I saw append-only-models-with-nhibernate by ayende, but wondering how to do that through mapping only?

Was it helpful?

Solution

The post append-only-models-with-nhibernate is a old post 15 Sep 2009 and may be at that time the method was there in that version of nHibernate. However I could not find the same in nHibernate 3.3 onwards. The reason unexplored. One cannot have Append only database model just way mentioned in the post.

However one can have and interceptor/event and collect the dirty objects and do evict from the session so that it can be inserted in the database again. I shall explore further and update the answer as to how to do the same.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top