The domain I shall use will based on events, that is events that people pay to book on to. I have vastly simplified the domain so that it looks like this:-
EventThis is where events are held, a typical event would be "Developers Forum" or "How to get ahead in business" etc. The event has a name and a time it starts and finishes.
Event PackageThis table holds the different packages that a visitor can book. For example a package could be:-
"Gold" - you get a better seat and a cup of tea
"Silver" - you get a seat but no tea
"Bronze" - you are forced to stand
Event VisitorAs you can see this table holds the people who are attending. A visitor can book more than one ticket so I have decided to use a hierarchical structure, that is the person who books has a ParentId of NULL and the additional people he/she books on will get a Id in ParentId.
Event PaymentThis table just keeps track of who has paid. Notice that I have denormalised this table a bit and have created a column called NoTickets sold.
Please note that this domain is for demonstration purposes as I just wanted to show how hierarchical structures can be used in NHibernate.
Next post will be how we create a C# project to map this domain