in reply to Re^2: Mapping objects to database tables
in thread Mapping objects to database tables
Okay ... for your problem domain, pull them back into the Death and Wedding table (but name them something better than xxx_1 and xxx_2 --- groom_first and bride_first may become un-pc but I'd worry about the downstream maintenance dev finding my home address than a PC fascist).
As for the abstraction to announcements - I'd model the domain before I'd model a model of the domain. Once you have a handle on the domain, then I'd look for further abstractions based on biz requirements. I've been burned way too many times by meta systems that make adding a new type fairly easy but asking a simple question like "how many deaths notices did we have for November" caused a monster headache of building a slew of objects and then asking each object are you of type "death" and did you occur in "november." While a straight sql to answer that question would take milliseconds - going through the object hierachy takes hours.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Mapping objects to database tables
by clinton (Priest) on Nov 07, 2006 at 14:08 UTC |