[thelist] DB Schema Design

Hassan Schroeder hassan at webtuitive.com
Sun May 7 16:44:26 CDT 2006

Matt Warden wrote:

>> True enough, but doesn't this assume that all the objects sharing
>> this status table will forever have exactly one "status"? Suppose
>> an existing object is extended (or a new one added) that requires
>> a primary and secondary status?
> No, this does not assume a single status.

OK, this is obviously one of those "more than one way to do it"
situations, but from my POV:

If "status" is an attribute of an object -- Customer, Product -- I
wouldn't implement it such that calls to Customer.getStatus() and
Product.getStatus() queried the same table, however indirectly. It
just feels like a potential maintainability problem to me, and I see
nothing to gain from it. But perhaps this is a unique situation. :-)

Hassan Schroeder ----------------------------- hassan at webtuitive.com
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com
                opinion: webtuitive.blogspot.com
                          dream.  code.

More information about the thelist mailing list