A
A
Anton Neverov2017-06-05 22:10:29
MySQL
Anton Neverov, 2017-06-05 22:10:29

How and where is it best to store large JSON/JavaScript arrays?

Hello!
There is a fairly large array of JavaScript by my standards.
Simplified example to understand the example construction:

{
    name: 'TEST',
    time: 1000,
    players: {
        '1': {
            name: 'Aim.Master',
            kills: 38,
            deaths: 20,
            weapons: {
                ak47: {
                    shoots: 10,
                    hits: 5,
                    kills: 20
                }, //Дальше следующие оружия...
            }
        }, //Дальше следующий игрок...
    }
}

The number of players is always limited. The number of weapons - has a certain limit.
Accordingly, the first thing I came up with was to simply put this array in one big piece in JSON format in a MySQL table. But I don't think this is the best solution. Perhaps there are any other ways?
Languages ​​at my disposal: Node.js, PHP, JavaScript.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Andrey Burov, 2017-06-05
@TTATPuOT

try mongodb

S
Shane Matte, 2017-06-07
@mattedev

Oddly enough in the database. I recommend postgresql

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question