B
B
Banny_Boom2015-08-06 18:30:30
PHP
Banny_Boom, 2015-08-06 18:30:30

How to properly build a database structure for multilingual records?

Please tell me how to build the structure correctly...
I will store dynamic records in the database to fill the template (title, meta tags, etc.)
How to build a table correctly so that I can get everything in 1 query?
I thought everything was simple in 1 line to write
id | link | title | meta key | description .... | language
but such a system does not seem quite correct to me, I don’t know exactly how many columns there will be, but it seems pretty decent to me ...
What do you advise?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
sim3x, 2015-08-06
@Banny_Boom

id | link | title__{lang1,lang2} | meta-key__{lang1,lang2} | description__{lang1,lang2} ....
or
tablename__{lang1,lang2} Depends
more on the orm and the orm plugins that will deal with such a
Pro

How to build a table correctly so that you can get everything in 1 query?
don't think first

I
Igor Vorotnev, 2015-08-06
@HeadOnFire

The architecture of multilingual data is an interesting thing. There are options and nuances. Read this article to get started .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question