0

I am just starting with nhibernate-envers so, please, bear with me. I am trying to manage a typical situation where I have customer and orders.

I would like to have different revisions for each entity.

I was wondering if it is possible to customize the the environment so that my customers have a progressive revision and my orders have another one, each starting from 1.

Thanks.

LeftyX
  • 35,328
  • 21
  • 132
  • 193
  • Can you explain why you need that? – Roger Mar 14 '14 at 21:02
  • I guess cause it's easier to understand. Let's say my order has got 8 revisions and a customer 1 but the customer is the last one to be saved. It would have rev. 9. If I want to show this info to a user I would have to figure out where are the others, query the db. – LeftyX Mar 17 '14 at 09:05
  • Ok. AFAIK - the revision number is not intended to be used as a "business value" but is a "technical number" used by Envers. Wrote an answer below. – Roger Mar 17 '14 at 09:50
  • FYI, even though Envers query api isn't complete or perfect, it's quite powerful. Dependending on what exactly you want to do, it may be something for you to look at. – Roger Mar 17 '14 at 21:15

1 Answers1

0

No. The revision number is a global number for your domain model (like a changeset number for a repository in a VCS).

Roger
  • 1,944
  • 1
  • 11
  • 17