1/20
A set of vocabulary flashcards covering the characteristics, pros, and cons of Graph, Column, Key-Value, and Document databases as described in the lecture notes.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai |
|---|
No analytics yet
Send a link to your students to track their progress
Relational Databases
Databases that use primary keys to prevent duplication, foreign keys to enforce referential integrity, and normal form rules to prevent anomalies, ensuring data is always consistent.
Graph Databases
A database type based on a mathematical graph where the key is made from the relationships between the data, often used in social media for relationship analysis.
Column Stores
A database model that uses tables but stores data in columns rather than rows, allowing rows to have varying numbers of columns.
Hashing
The process where a key is mapped to another value using a hash function to determine its storage location in a data structure called a hash table.
Key collisions
Problems that occur in key-value stores when a poor hash function results in multiple keys attempting to use the same storage location.
Key-value Stores
Databases that function as giant hash tables where unique keys are mapped to records with different fields, often providing O(1) retrieval performance.
Key-Value Performance
Systems that can have a large number of records and still retrieve values quickly if the key is known, often achieving O(1) consistency performance due to hashing.
Key-Value Operations
A limited set of basic commands consisting only of "PUT", "GET", and "DELETE" operations, which do not support complex queries.
Document Databases
A NoSQL database type that uses a document-oriented model to store self-contained data where each document may use different fields.
Document vs. Key-value Retrieval
In key-value stores "GET" returns the entire field, whereas in document databases it can return specific parts of the field.
Document Database Operations
Permits basic operations known as create, read, update, and delete, and can be accessed via programming languages.
Graph Databases PROS
Excellent for interconnected data. Doesn’t require a lot of joins, giving it a flexible schema.
Column Stores PROS
Efficient for analytical queries as its easy to search for colums, and to retrieve values
Hashing PROS
Fast data retrieval, efficient use of space.
Key-value Stores PROS
No need to ensure consistency due to hashing + allows a variety of data values that can be retrieved quickly with the key
Document Databases PROS
Flexible schema and able to store diverse data types.
Graph Database CONS
as graph gets bigger and more people join the network, it can slow down and become harder to scale
Column Stores CONS
Cons: Not ideal for transactional operations, as it’s hard to search for and add to rows
Hasing CONS
poor hash functions can cause key collisions.
Key-value stores CONS
lack of referential integrity means the different data values can lead to contradictions as mistakes aren’t being checked
Document database CONS
can only perform basic operations and has no normalisation