D
D
devAston2019-10-10 11:07:54
Laravel
devAston, 2019-10-10 11:07:54

How to properly organize relationships of one table to many tables (using migrations)?

There are tables History , Project , Blog .
How to correctly organize the relationship of History to the other two tables? An entry in the History
table can only be linked to one of the two tables.

Eg.

  1. Запись Истории #1 относиться к записи Блога #1
  2. Запись Истории #2 относиться к записи Блога #1
  3. Запись Истории #3 относиться к записи Блога #2
  4. Запись Истории #4 относиться к записи Блога #3
  5. Запись Истории #5 относиться к записи Проект #1

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question