3 ms·
I'm not GP, but I don't know what about Mongo's API is fantastic, or, frankly, even good (and I like mongo fine as a database). It is overly verbose, and, witho
by zbentley 7y ago
I'm not GP, but I don't know what about Mongo's API is fantastic, or, frankly, even good (and I like mongo fine as a database). It is overly verbose, and, without a good set of client utilities, feels more like writing instructions for a black box query planner than asking for data from a database. SQL is vastly superior.
- Too 7y agoMongodb aggregation queries are far more intuitive and easy to explain to juniors than sql, because they run in the order you write them and don't need blog posts like https://jvns.ca/blog/2019/10/03/sql-queries-don-t-start-with-select/ https://jvns.ca/blog/2019/10/03/sql-queries-don-t-start-with... (just found this on front page on HN). Well, actually there is a query planner in between also but they run as-if they were executed in that order. Anyway. They also by default protect you from sql injections and are easier to construct programmatically because appending a step in the pipeline is literally just appending to a standard json array, without having to know the complete lexer and AST of SQL and all. On the other hand they do make you pretty tired of curly brackets :)