I have a rather large class hierarchy that I'd like to use table per hierarchy with, but with a slight twist. My hierarchy looks like:
Event --> [specific_events] --> Transaction --> [specific_transactions]
I'd like to split this hierarchy into two tables, Event and Transaction. However, all transactions are events, and I believe NHibernate will attempt to put the entire hierarchy in the Event table.
How can I tell it to split the hierarchy between Events and Transactions?
EDIT: I got the hierarchy slightly wrong. All specific_events derive from Event and all Transactions derive from Event, not specific_events.
Event --> [specific_events]
Event --> Transaction --> [specific_transactions]
"I'd like to split this hierarchy into two tables, Event and Transaction. However, all transactions are events, and I believe NHibernate will attempt to put the entire hierarchy in the Event table."
But it is possible to put all the events in the one table and put all transaction in another table, however per each transaction there will be an entry in the event table - Low Flying Pelican 2012-04-04 04:45
It is not possible as I know. Why do you want to split them in 2 different tables?
Also there is a very good explanation about different strategies for hierarchy mappings in NHibernate in Action book. It helped me a lot.