J
J
Javarast Skriptovich2018-12-13 07:31:14
Node.js
Javarast Skriptovich, 2018-12-13 07:31:14

File or database?

When should you use a DBMS and when should you use a file?
Where is it more expedient to store a log of errors or actions, where to store monotonous data (for example, a list of digital keys that are erased after a sale), etc.?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
DevMan, 2018-12-13
@M4mkin_pr0ger

The database is needed where there is really a lot of data and / or they need to be operated on.
Logs can be stored both in a file (by setting the rotation) and in the database. Simply because the data from the logs is rarely analyzed.
The keys for sale are stored in the database stupidly for accounting, so that each Vasya can be shown which keys he bought.
Well, the icing on the cake-db is a private type of files.

L
Lazy @BojackHorseman, 2018-12-13
Tag

when the file search speed ceases to satisfy, then they take a database that can sort data out of the box and thereby speed up the search. only and everything.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question