What is document data store? What is key-value data store?
Please, describe in very simple and general words the mechanisms which stand behind each of them.
What is document data store? What is key-value data store?
Please, describe in very simple and general words the mechanisms which stand behind each of them.
From wikipedia:
More examples at NoSQL.
In a document data store each record has multiple fields, similar to a relational database. It also has secondary indexes.
Example record:
"id" => 12345,
"name" => "Fred",
"age" => 20,
"email" => "[email protected]"
Then you could query by id, name, age, or email.
A key/value store is more like a big hash table than a traditional database: each key corresponds with a value and looking things up by that one key is the only way to access a record. This means it's much simpler and often faster, but it's difficult to use for complex data.
Example record:
12345 => "Fred,[email protected],20"
You can only use 12345 for your query criteria. You can't query for name, email, or age.
Here's a description of a few common data models: