Answer the question
In order to leave comments, you need to log in
What would be the optimal table structure in my case?
Are there best practices on the structure of tables in terms of extensibility / performance for the following task:
There is a table of records (posts): id, datetime, title, text
Hashtags (#tag, #othertag ... etc.) are extracted from the text line
. entries can be attached links to media content - photos, videos. Such "attaches" can be from 1 to ... 100 for example.
Question: how to store all this?
1. Attachments in a separate table and attached by record id or in some other way?
2. Hashtags are also a separate table, or better, a simple enumeration in a separate line of the table of the entry itself.
Which is more economical in terms of database load when displaying lists of posts / searching by posts / searching by hashtags? Are there standard solutions of such a structure?
Answer the question
In order to leave comments, you need to log in
Attachments in a separate table and attach by record id or something else?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question