Databases Flashcards
What is a database?
A database is an organized collection of structured information or data, typically stored electronically in a computer system.
True or False: A relational database stores data in tables with predefined relationships.
True
Fill in the blank: In a relational database, a _______ is a unique identifier for a record in a table.
primary key
What is SQL?
SQL (Structured Query Language) is a standard programming language used to manage and manipulate relational databases.
What does ACID stand for in database transactions?
Atomicity, Consistency, Isolation, Durability
Multiple Choice: Which of the following is not a type of database? A) SQL B) NoSQL C) HTML D) NewSQL
C) HTML
What is the purpose of an index in a database?
An index improves the speed of data retrieval operations on a database table.
True or False: A NoSQL database is designed to handle unstructured data.
True
Fill in the blank: A _______ is a collection of related data entries and it consists of multiple records.
table
What is normalization in databases?
Normalization is the process of organizing data to minimize redundancy and improve data integrity.
Multiple Choice: Which of the following is a characteristic of a NoSQL database? A) Fixed schema B) Horizontal scalability C) Use of SQL D) Rigid data structure
B) Horizontal scalability
What is a foreign key?
A foreign key is a field in one table that uniquely identifies a row of another table, establishing a relationship between the two tables.
True or False: A stored procedure is a set of SQL statements that can be stored and reused.
True
Fill in the blank: The _______ command in SQL is used to retrieve data from a database.
SELECT
What is data redundancy?
Data redundancy occurs when the same piece of data is stored in multiple places within a database.
Multiple Choice: Which of the following is a type of NoSQL database? A) Document store B) Relational C) Object-oriented D) Hierarchical
A) Document store
What is a database management system (DBMS)?
A DBMS is software that interacts with end users, applications, and the database itself to capture and analyze data.
True or False: Data integrity ensures accuracy and consistency of data over its lifecycle.
True
Fill in the blank: In SQL, the _______ clause is used to filter records.
WHERE
What is a transaction in the context of databases?
A transaction is a sequence of operations performed as a single logical unit of work.
Multiple Choice: Which of these is a benefit of using a database? A) Data isolation B) Data redundancy C) Reduced data integrity D) Increased complexity
A) Data isolation
What does the term ‘data model’ refer to?
A data model is a conceptual representation of data structures that organizes data elements and standardizes how they relate to one another.
True or False: A schema defines the structure of a database including tables, fields, and relationships.
True
Fill in the blank: The _______ command is used to remove records from a table in SQL.
DELETE
What is a view in a database?
A view is a virtual table based on the result set of a SQL query.
Multiple Choice: Which of these is an example of a SQL database? A) MongoDB B) PostgreSQL C) Cassandra D) Redis
B) PostgreSQL
What is denormalization?
Denormalization is the process of intentionally introducing redundancy into a database to improve read performance.
True or False: A data warehouse is designed for transaction processing.
False
Fill in the blank: The _______ command in SQL is used to update existing records.
UPDATE
What is the purpose of a database trigger?
A trigger is a set of instructions that are automatically executed in response to certain events on a particular table or view.
Multiple Choice: Which of the following is a characteristic of a relational database? A) Schema-less B) Data is stored in key-value pairs C) Uses tables D) Unstructured data
C) Uses tables
What is horizontal scaling?
Horizontal scaling involves adding more machines or nodes to a system to handle increased load.