Hi,
Hypothetically, if I had a online shopping mall with different types of products like , clothes, books, etc, that would have extra data depending on what type they are. In
java, it seems like the best way to approach that would be to have a general product class and then child classes for items with more data specific to their type.
If I were to persist that, how would you design the table structure? I was thinking that you'd have a product table and some way to point to the extra data table and a foreign key. But since there's multiple extra tables how could you point to the right table? Or is the overall design in question flawed?
Thanks!!!