Re: Polymorphism in RDBMS

From: Senny <>
Date: Fri, 23 Apr 2004 17:47:57 GMT
Message-ID: <hFcic.1378$>

Polymorphism is irrelevant here. A given piece can be credited to some single entity, regardless of whether that entity is a single human being or a collective of human beings. All you need to do is associate each song with an entity.

There are numerous ways of doing this, none of which is necessarily the right way (since we don't know the whole situation), so I won't bother designing a database right here. Your code can be as polymorphic as you like, although I don't know why you *should* make it polymorphic in this case. Anyhow, the point is that in this question of data storage, polymorphism is irrelevant--a big, fat, juicy, red herring.

If you rephrase your question a bit, you might get farther.


Ian Pilcher wrote:

> Sorry I wasn't clear. I don't plan to eliminate the group_info and
> person_info tables. I do, however, need a way to associate a piece of
> music with an "artist", regardless of whether the artist is a group or
> an individual.
> I need to "combine" polymorphism and an RDBMS because music can be
> written/arranged/performed by either "groups" or people. In this case,
> the real world is very much "polymorphic".
Received on Fri Apr 23 2004 - 19:47:57 CEST

Original text of this message