Answer the question
In order to leave comments, you need to log in
What is the best way to store a large list of parameters in MySQL? Structure design
There are many elements, for example "cars" and each element has a large number of different parameters, for example: truck, new, repair, automatic, left-hand drive, etc...
Previously, we stored everything like this:
CREATE TABLE IF NOT EXISTS `example` (
`id_car` int(11) unsigned NOT NULL AUTO_INCREMENT,
`a` tinyint(1) unsigned NOT NULL,
`b` tinyint(1) unsigned NOT NULL,
`c` tinyint(1) unsigned NOT NULL,
PRIMARY KEY (`id_car`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
Answer the question
In order to leave comments, you need to log in
Select these parameters in a separate table, many-to-many relationship
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question