A
A
Alexander2017-07-18 14:37:41
PostgreSQL
Alexander, 2017-07-18 14:37:41

What database to use for node.js server API?

I want to understand what is better for my task: PostgreSQL or MongoDB. I will write SPA on vue.js and node.js. There will be a fairly dynamic interface, so most likely almost all communication between the client and the server will go through websockets. I constantly see that everyone uses MongoDB with node.js. Although I myself have some doubts about its benefits. As I understand it, in noSQL it is usually customary to duplicate some data due to the convenience of extracting data from the database, but this can lead to data inconsistency and conflicts in the future. Also, as far as I know, PostgreSQL is significantly ahead of MongoDB in terms of performance. Many people say that mongo is a better fit for javascript because of its object architecture. So I can't figure out what to choose.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question