A
A
arakul232018-08-20 15:31:24
Database design
arakul23, 2018-08-20 15:31:24

How to store characteristics for different product categories?

Tell me, how to properly store characteristics for different categories of goods in the database, so that later they can be pulled out for a certain category?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Andrey Skorzhinsky, 2018-08-21
@AndyKorg

A category directory with an artificial primary key and a product directory with a category foreign key.

S
sim3x, 2018-08-20
@sim3x

json - we store everything in the product, if the signs in the category need to be changed in bulk - we go through the script through all of them. json in postgres is slightly faster than EAV
EAV - a
redis classic or even its own binary file - we store signs in the form of binary masks, for very fast filtering (there was an article on Habré)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question