No pre-defined schema required
I’m sorry, this is completely untrue. I don’t mean to be rude, this entire section is totally misleading.
If you’re using Oracle, or any other SQL database, you have to decide in advance how to design every table and what fields to put in each table. This is called a database schema, and it’s difficult to get this right the first time.
Yes, you have to define it in advance, but you have to do that with NoSQL too. With SQL, you don’t have to get it right the first time, you can easily add/drop columns/indexes, etc…I work in an organization where we do this all the time…and yes, to millions of rows.
There is no such restriction with MongoDB, because there’s no need to define a schema in advance.
Perhaps in the simplest of tutorial examples, this statement could be true. But for all real intents and purposes it is not. With NoSQL, in order to search your data you still need columns and indexes and whatnot, and if you don’t define things properly it’s a MAJOR pain to refactor it. If you don’t define a field, you can’t search on it, and it’s difficult to add such fields later. It’s barely organic. SQL is more organic.
It’s perfect, for example, for storing an Electronic Medical Record (EMR) with information about prescriptions that could vary in future.
This is true…for storage…but if you want to get to the data, to search for it in some way, you have to identify it with keywords, pull data out so that it’s available in a field, etc. You can’t just stuff a bunch of random PDFs into a Mongo database and expect to be able to find one of the later by address…you still have to pull the address out into a searchable field in order to get to it. It’s not magic. It’s not intelligent. It can’t see “oh, that PDF seems to have an address top left, while this one has one top right…and that one doesn’t have an address because it’s a picture of a dog…and hey, I even know what an address is!”. That AI-level technology doesn’t exist yet. Too often people use this kind of “magical language” when discussing the benefits of NoSQL, and it’s completely misleading. Humans still have to provide the structure by which to get the data back out, and this is no different from SQL.
Ah, there we go. The biggest (and only real) benefit of NoSQL in general. This benefit is huge, but it can also be a drawback because again, you have to structure how the data is split horizontally and you have to foresee this in advance. If you structure the splits wrong, you could end up having one or two servers with most of the data, and a dozen other servers with a minimum of data…and migrating THAT to a more efficient structure is time-consuming and probably requires down-time.
And while horizontal scaling is performant for document storage, overall it really depends on the kind of data you are querying. Nothing will beat the performance of searching “index on last_name” if you can keep that all in RAM on one server. SQL databases are still the most efficient and effective solution for most people and most businesses, and you can get most of the benefits of NoSQL just by storing “documents” in a BLOB field.
– full disclosure: I did own some MDB before Covid but sold to simplify my portfolio and have a backstop in case of job loss. I think MDB can do well, so my commentary is not on the company’s prospects…only the hype that seems to surround it.