Y
Y
yurygolikov2017-03-09 10:03:39
MySQL
yurygolikov, 2017-03-09 10:03:39

How to properly build the table architecture in my case? How not to produce tables?

It needs to be implemented using a relational data model.
Preferably compatible with MySQL capabilities.
I will give a simplified example of what needs to be implemented:
1. There are data of different types. Types (attributes) of data will constantly expand (types are not known in advance).
Example:

data_1 data_2 data_3 (в дальнейшем будут добавлятся) data_4 data_5 ...

2. Data units can be added as related or unrelated groups. These groups are fixed, but can also expand as the data expands.
For example, groups might look like this:
Группа №1 data_1 data_2 
Группа №2 data_1 data_2 data_3 data_4
Группа №3 data_5 data_6
(И группы могут расширятся по мере расширения данных)
Группа №4 data_3 data_4 data_7 data_8

3. This entity must contain a different set of groups. Also expands as new groups are added.
For example:
Группа №1 Группа №2
Группа №3 Группа №4
Группа №1 Группа №2 Группа №3 Группа №4
(И группы могут расширятся по мере расширения данных)
Группа №3 Группа №4 Группа №5 Группа №6

I do not ask you to decide for me, I ask you to leave keywords that I most likely do not know.
Please do not scold, the theory of relational databases, I know only the basics.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
sowenok, 2017-03-09
@yurygolikov

1. I advise you to read it in full, well, and so the section "Vertical tables":
https://ruhighload.com/post/%D0%94%D0%B5%D0%BD%D0%...
and 2 and 3 are ordinary link tables . I think in this article you will find the answer to your questions.

I
igruschkafox, 2017-03-09
@igruschkafox

Store groups in XML format in a separate table
, and in the line where you need to specify a certain set (Group), pass the Group ID

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question