mongodbrelational-databaseschemalessnosql

Why is it called NoSQL?


I've recently worked with MongoDB and learned about its schemaless design. However, I'm confused with the term NoSQL? Why is it called that? Doesn't it use SQL or SQL-like queries?

I've also read from an article that the main difference lies in how data is stored. Is this true? In the case of MongoDB, it's stored like JSON documents.

Also, I'm confused why I always see 'NoSQL vs relational databases'. Aren't NoSQL databases relational? I believe documents in MongoDB are still related/linked through some keys (please correct me if I'm wrong). So why is it labeled as non-relational?

Thanks in advance!


Solution

  • Doesn't it use SQL or SQL-like queries?

    While "non-relational databases" might be a more accurate name, most of them do in fact not use SQL or something similar.

    Aren't NoSQL databases relational? I believe documents in MongoDB are still related/linked through some keys (please correct me if I'm wrong). So why is it labeled as non-relational?

    NoSQL databases are non-relational databases.

    They come in a variety of flavours (mainly "document databases", "key-value stores", and "graph databases"), but you usually don't get any or all of the following "relational" features:

    (What you get by giving up some of these handy features is improved performance, availability and scalability).