I want to implement products filtering in category and I have questions about the right DB schema. For now I have the following tables:
Categories:
1. id
2. category
3. description
Products:
1. id
2. category_id
3. product
4. image
5. price
Attributes:
1. id
2. attribute
Category_Attributes:
1. category_id
2. attribute_id
And the question I have is what tables should I create and what columns shout they have to store different kinds of values, attribute values, products attribute values etc.
Would it be normal to create 3 more tables:
Values:
1. id
2. value
Attributes_Values:
1. attribute_id
2. value_id
Products_Attributes_Values:
1. product_id
2. attribute_id
3. value_id
I've messed up in last tables. What would be better to store and filter?