Is NoSQL ideal for storing statistics?

I am not very familiar with NoSQL systems, but I remember reading some time ago that they are ideal for processing statistical data.

Since I'm going to start writing code that will record data such as β€œhow many users were logged in every day,” I thought I could use this as an opportunity to learn more about NoSQL if it matches the account.

If NoSQL is really perfect for this, could you give me some information on why? And which specific systems are best suited for this particular need?

So, after the first answer, it may be useful to clarify a little more.

I currently have a PostgreSQL database from which I will get data. It will be very simple and no calculations are required. For example, I will get a result set with the number of users registered every day for the last month (so it will just be a set of value pairs for date / users) and save it in another table / database.

Thanks!

+4
source share
2 answers

It depends on what types of analysis you will do on these statistics. If you are going to perform many different operations (averaging, summing, joining ...), you may find NoSQL solutions more painful than they are worth it.

However, if you save statistics mainly for display purposes or for very specific analysis procedures, NoSQL solutions begin to glow.

If your data is small enough, stick to the SQL solution, which will give the advantage of a complete query mechanism for work, but if you have many values ​​(one value per day is nothing, even if you work for a million years), and worry about the size and performance of the storage, NoSQL options can once again be worth it.

If your data is semi-structured, take a look at CouchDB, which offers some rudimentary indexing and query support, which can serve as the basis for analysis procedures. If you keep individual values ​​with a very small structure, my best advice would be to look at the Tokyo cabinet and Tokyo Tyrant, which are absolutely incredible options for storing keys.

+5
source

NoSQL systems tend to optimize when data is often stored, but not often accessed. In the case of statistics, you can collect a lot of data from a (social) site, often in small bits, for which it is optimized. But the search and analysis can be slower ... Of course, it depends on which "NoSql" system you decide to use.

0
source

Source: https://habr.com/ru/post/1305034/


All Articles