Main Idea | Explanation | Examples | Key Terms |
---|---|---|---|
Hierarchical Model | Data is organized in a tree-like structure with parent-child relationships. | File systems, IBM Information Management System (IMS) | Tree Structure, Parent-Child |
Network Model | Data is organized as a graph where records can have multiple parent and child relationships. | Integrated Data Store (IDS), IDMS | Graph, Many-to-Many Relationships |
Relational Model | Data is stored in tables (relations) with rows and columns, and relationships are defined using keys. | MySQL, PostgreSQL, Oracle | Tables, Primary Key, Foreign Key |
Object-Oriented Model | Data is stored as objects, similar to object-oriented programming concepts, with attributes and methods. | GemStone, ObjectDB | Objects, Attributes, Methods |
Document Model | Data is stored as documents, typically in JSON or XML format, suitable for unstructured or semi-structured data. | MongoDB, Couchbase | Documents, JSON, Collections |
Key-Value Model | Data is stored as key-value pairs, often used for caching and fast lookups. | Redis, DynamoDB | Key-Value Pairs, Hashing |
Columnar Model | Data is stored in columns rather than rows, optimized for analytics and large-scale queries. | Apache Cassandra, HBase | Columns, Column Families |
Graph Model | Data is stored as nodes and edges, representing relationships explicitly. | Neo4j, Amazon Neptune | Nodes, Edges, Relationships |
Time-Series Model | Data is organized and optimized for time-stamped data, useful for metrics or logs. | InfluxDB, TimescaleDB | Time-Stamps, Sequences |
Spatial Model | Data is designed for spatial data types like maps and geographic locations. | PostGIS, ArcGIS | GIS, Spatial Indexing |
Quick Notes:
- Hierarchical and Network Models are older models focusing on rigid structures.
- Relational Model is widely used and supports SQL.
- Object-Oriented and Document Models are ideal for modern applications.
- Graph and Time-Series Models are specialized for specific use cases like relationships and logs.
MCQ
Which database model organizes data in a tree-like structure with parent-child relationships?
A) Relational Model
B) Hierarchical Model
C) Network Model
D) Graph Model
Answer: B
In which database model are relationships defined using primary and foreign keys?
A) Network Model
B) Document Model
C) Relational Model
D) Key-Value Model
Answer: C
Which database model is best suited for applications requiring many-to-many relationships?
A) Hierarchical Model
B) Network Model
C) Key-Value Model
D) Columnar Model
Answer: B
In the Document Model, data is commonly stored in which formats?
A) CSV and TSV
B) JSON and XML
C) PDF and TXT
D) SQL and HTML
Answer: B
Which database model is best for unstructured or semi-structured data?
A) Relational Model
B) Document Model
C) Hierarchical Model
D) Network Model
Answer: B
For a social network application, which database model is most suitable to represent relationships?
A) Graph Model
B) Relational Model
C) Key-Value Model
D) Columnar Model
Answer: A
Which database model is optimized for analytics and large-scale queries?
A) Columnar Model
B) Key-Value Model
C) Time-Series Model
D) Object-Oriented Model
Answer: A
Which of the following database models is commonly used for caching due to its simplicity and speed?
A) Document Model
B) Relational Model
C) Key-Value Model
D) Graph Model
Answer: C
In the Hierarchical Model, each child node:
A) Can have multiple parents
B) Can have only one parent
C) Cannot have any parent
D) Has no restrictions on relationships
Answer: B
Which database model stores data as objects with attributes and methods?
A) Object-Oriented Model
B) Columnar Model
C) Document Model
D) Time-Series Model
Answer: A
Which database model is specifically designed to handle geographic and spatial data?
A) Time-Series Model
B) Spatial Model
C) Relational Model
D) Document Model
Answer: B
For metrics and logs organized by timestamps, which database model is most appropriate?
A) Graph Model
B) Time-Series Model
C) Network Model
D) Key-Value Model
Answer: B