I'm facing a dilemma in my database design for an upholstery store.
This store cleans carpets, pillows, car seats, car trunks, couches.
There are chairs and sofas with fixed and removable seat cushions. Car seats and trunks with different sizes. The same occurs with pillows.
From my point of view all of these things are items. My idea is to create a table like this:
CREATE TABLE Item ( ItemID … Name … Description … Material … -- (like 'cotton', 'wool', 'rayon', 'silk') Length … Height … Width … );
The items mentioned earlier have sub items. A car has seats and trunk. A chair can have a fixed or a removable seat, a couch can have pillows and so on.
I've read these posts:
- Sub and sub sub items organization
- What is Parent/Child relationship
- Parent/Child relationship best practice
- Items with sub items
After reading them, I have some questions:
- Is it a good idea to include another column called
subItemwhich references a parent
itemfrom the same table? Doing that it hurts performance?
- Is this a case of a
I'm wondering what approach fits simpler for maintenance and performance.