1/299
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai |
|---|
No analytics yet
Send a link to your students to track their progress
A scientist collects temperature readings, satellite images, and audio recordings of bird calls for a climate study. Collectively, what are these items called?
Data
3 multiple choice options
A vinyl record stores music as continuous grooves, while a music file on a phone stores it as a series of discrete numbers (0s and 1s). This represents the difference between which two data formats?
Analog and Digital
3 multiple choice options
An online store organizes all its product information, including names, prices, and quantities, into a set of structured tables for easy retrieval and management. What is this organized collection called?
A database
3 multiple choice options
What is the primary role of a Database Management System (DBMS)?
To act as the software that manages and controls access to a database
3 multiple choice options
An analyst uses the command "SELECT Name FROM Customers WHERE City = 'London';" to get a list of customer names. The command itself is an example of what?
A query
3 multiple choice options
A bank customer wants to check their account balance. They open a mobile app on their phone and tap a "View Balance" button. What component did the customer interact with directly?
The database application
3 multiple choice options
A data breach occurred at a company. The person responsible for investigating, determining who had access to what data, and securing the system against future attacks holds which database role?
Database Administrator
3 multiple choice options
Before any data is stored, a person is tasked with defining the structure of the database, including all tables, columns, and the relationships between them. What is this person's role?
Database Designer
3 multiple choice options
A software developer is writing Python code that will connect to a database to retrieve and display user information. Which role is this developer performing?
Database Programmer
3 multiple choice options
A small business tracks its inventory in a single spreadsheet. As the business grows, they find that multiple employees editing the file at once leads to errors and corrupted data. A DBMS is better suited for this situation primarily because it can handle:
Complex requirements
3 multiple choice options
A manager should only be able to see the salary information for employees in their own department. The DBMS feature that controls this is called:
Authorization
3 multiple choice options
When you purchase a movie ticket online, the system must both reserve your seat and process your payment. If either step fails, the entire operation must be canceled. This all-or-nothing principle describes a:
Transaction
3 multiple choice options
Imagine a transaction to transfer $100 from Account A to Account B. If the system crashes after successfully debiting $100 from Account A but before crediting Account B, what should the DBMS do upon restarting?
Roll back the transaction, returning the $100 to Account A
3 multiple choice options
When you submit an SQL query, which internal component of the DBMS parses the query, checks it for correctness, and determines the most efficient way to access the data?
Query Processor
3 multiple choice options
In a DBMS, which component is responsible for reading and writing data on the physical disk?
The Storage Manager
3 multiple choice options
To execute a query, the query processor needs information about the tables, columns, and indexes in the database. Where does it find this metadata?
The Database Catalog
3 multiple choice options
A sudden power outage corrupts a database. The Database Administrator uses the transaction log to undo incomplete transactions and restore the database to a consistent state. This process is known as:
Recovery
3 multiple choice options
What is the defining characteristic of a relational database?
Data is organized into tables that consist of rows and columns
3 multiple choice options
A developer is building an application with rapidly changing data requirements and large amounts of unstructured data. Which type of database would be most suitable?
NoSQL Database
3 multiple choice options
A company chooses to use PostgreSQL, a database whose source code is freely available for anyone to view, modify, and distribute. This type of software license is known as:
Open Source
3 multiple choice options
A startup is looking for a powerful relational database that requires no initial licensing fees and allows their developers to view the source code. Which of the following systems best fits their need for an open-source license?
PostgreSQL
3 multiple choice options
An application needs to add a new customer to a Customers table. Which CRUD operation does this represent?
Create
3 multiple choice options
Which language is the international standard for querying and manipulating data in relational databases?
SQL
3 multiple choice options
When creating a table in SQL, what is the purpose of specifying a data type like DECIMAL(8, 2) for a Price column?
It defines that the column can hold numbers with a total of 8 digits, with 2 of those digits after the decimal point
3 multiple choice options
The acronym CRUD describes the four fundamental operations in a database. What do the letters stand for?
Create, Read, Update, Delete
3 multiple choice options
What are the three primary phases of the database design process, in the correct order?
Conceptual, Logical, Physical
3 multiple choice options
In a standard Entity-Relationship (ER) diagram, what is the primary purpose of rectangles?
To represent the entities
3 multiple choice options
What is the main goal of the conceptual design phase?
To understand and document the business requirements and high-level data entities
3 multiple choice options
What is a database schema?
The formal blueprint of a database, defining its structure, tables, and relationships
3 multiple choice options
The process of deciding to create an index on a frequently searched column belongs to which design phase?
Physical design
3 multiple choice options
What is the principle of data independence in database design?
Changes can be made to the internal structure of the database without affecting the external view of the data
3 multiple choice options
What is the purpose of a database API (Application Programming Interface), such as JDBC or ODBC?
It provides a standard way for application code to communicate with a database, regardless of the specific database vendor
3 multiple choice options
A formal database model is a framework that specifies which three components?
Data Structures, Operations, and Integrity Rules
3 multiple choice options
What is the main output of the logical design phase?
A detailed, technology-independent schema showing tables, columns, and relationships
3 multiple choice options
Which database model became dominant in the 1980s and is based on a tabular data structure?
Relational
3 multiple choice options
The emergence of the internet and its massive volumes of unstructured data (big data) spurred the development of which type of database system?
NoSQL databases
3 multiple choice options
What was a primary reason that older models like hierarchical databases were initially faster than early relational databases?
Their data structures were less abstract and more closely tied to the physical storage layout
3 multiple choice options
In the relational model, what is a row, representing a single instance of an entity, also known as?
A tuple
3 multiple choice options
In relational theory, what is the mathematical term for a table?
A domain
3 multiple choice options
Which relational algebra operation returns only the rows from a table that satisfy a given condition?
SELECT
3 multiple choice options
Which relational algebra operation returns only specified columns from a table?
PROJECT
3 multiple choice options
Which of the following is an example of a relational rule, as opposed to a business rule?
A primary key value cannot be NULL.
3 multiple choice options
What is the key difference between a relational rule and a business rule?
Relational rules are about data structure and integrity and are universal to the model, while business rules are specific to an organization's operations.
3 multiple choice options
What is a key difference between a mathematical set and a tuple?
A tuple is an ordered collection of elements, while a set is an unordered collection that does not allow duplicates
3 multiple choice options
Which SQL statement is used to modify existing records in a table?
UPDATE
3 multiple choice options
In an ER Diagram for a university, a line labeled "advises" between a Professor entity and a Student entity represents what?
A relationship
3 multiple choice options
What is a primary strength of Document databases like MongoDB?
A flexible schema that allows for storing unstructured and evolving data easily
2 multiple choice options
A database administrator needs to create a new Products table. Which sublanguage of SQL would they use for this task?
Data Definition Language (DDL)
3 multiple choice options
A user updates their phone number in their profile on a website. In the background, a statement is executed. This statement is part of which SQL sublanguage?
Data Manipulation Language (DML)
3 multiple choice options
A banking application needs to ensure that a transfer of funds is completed entirely or not at all. Which sublanguage, containing commands like COMMIT and ROLLBACK, manages these operations?
Data Transaction Language (DTL)
3 multiple choice options
A security officer needs to give a new data scientist read-only access to a specific table. Which sublanguage would be used?
Data Control Language (DCL)
3 multiple choice options
In the SQL statement "SELECT FirstName FROM Employees;", what is FirstName?
An identifier
3 multiple choice options
In the SQL statement "UPDATE Products SET Price = 29.99 WHERE ProductID = 101;" , what is 29.99?
A literal
3 multiple choice options
In the SQL statement "INSERT INTO Customers (Name) VALUES ('John Smith');", what is INSERT?
A keyword
3 multiple choice options
A developer adds the line "-- Retrieve all active users to their SQL script to explain its purpose." How will the database system treat this line?
It will ignore the line completely
3 multiple choice options
In a formal SQL syntax definition, what do square brackets [] around a clause indicate?
The clause is optional and may be omitted
3 multiple choice options
Before running a script that creates several tables, a developer wants to ensure they are working within the correct database. Which command should they use to select SalesDB as the default database?
USE SalesDB;
3 multiple choice options
A developer wants to see the column definitions for a table named Employees. Which command would provide this information?
SHOW COLUMNS FROM Employees;
3 multiple choice options
Which of the following is a fundamental rule for relational tables?
Each column in a table must have a unique name
3 multiple choice options
What is the principle of data independence?
The physical storage of data can be changed without affecting the applications that query it
3 multiple choice options
A developer needs to add a HireDate column to an existing Employees table. Which command should they use?
ALTER TABLE Employees ADD HireDate DATE;
3 multiple choice options
To store the number of employees in a small company (which will not exceed 30,000), which integer data type offers the best storage efficiency?
SMALLINT
3 multiple choice options
Which data type is most appropriate for storing a product's price, such as $19.99, to ensure precision in calculations?
DECIMAL(10, 2)
3 multiple choice options
A developer needs to store a 2-letter US state code (e.g., 'TX', 'CA'). Which data type is the most efficient choice?
CHAR(2)
3 multiple choice options
A table needs to store a complete timestamp, including the date and time a record was created. Which data type is most suitable?
DATETIME
3 multiple choice options
Which INSERT statement correctly adds a new department to a Departments table with columns (ID, Name)?
INSERT INTO Departments (ID, Name) VALUES (10, 'Marketing');
3 multiple choice options
A Products table has a Status column with a DEFAULT value of 'Active'. What happens if a new product is inserted without specifying a Status?
The Status column will be automatically set to 'Active'
3 multiple choice options
Which statement correctly modifies the price of the product with ID 5 to $99.99 in the Products table?
UPDATE Products SET Price = 99.99 WHERE ID = 5;
3 multiple choice options
A manager decides to discontinue all products in the 'Electronics' category. Which statement correctly removes all of these products from the Products table?
DELETE FROM Products WHERE Category = 'Electronics';
3 multiple choice options
What is the main purpose of a primary key in a table?
To uniquely identify each row in the table
3 multiple choice options
A table tracking student course enrollments needs a primary key. A student can enroll in many courses, and a course can have many students. Which of the following would be the best choice for a primary key for the Enrollments table?
StudentID and CourseID
3 multiple choice options
A developer sets the ID column of a table to AUTO_INCREMENT. What is the primary benefit of this?
It automatically generates a new, unique numeric value for each inserted row
3 multiple choice options
What is the purpose of a foreign key?
To create a link between two tables by referring to the primary key of another table
3 multiple choice options
A Departments table has a ManagerID column that is a foreign key referencing the ID in the Employees table. What does this relationship imply?
Every value in ManagerID must correspond to an existing employee ID
3 multiple choice options
A HealthPlan table needs to link to a specific dependent of an employee. The Family table has a composite primary key of (EmployeeID, DependentNumber). What must the foreign key in the HealthPlan table be?
(EmployeeID, DependentNumber)
3 multiple choice options
The rule that ensures that a foreign key value must match an existing primary key value (or be NULL) is called:
Referential integrity
3 multiple choice options
A database contains an Orders table with a CustomerID foreign key. Which of the following actions would violate referential integrity?
Inserting a new order with a CustomerID that does not exist in the Customers table
3 multiple choice options
An Invoices table has a foreign key to a Customers table. The foreign key constraint is defined with ON DELETE RESTRICT. What happens if a user tries to delete a customer who has existing invoices?
The delete operation is rejected and fails
3 multiple choice options
An Invoices table has a foreign key to a Customers table. The foreign key constraint is defined with ON DELETE CASCADE. What happens if a user tries to delete a customer who has existing invoices?
The customer is deleted, and all their invoices are also deleted
3 multiple choice options
An Invoices table has a foreign key to a Customers table. The foreign key constraint is defined with ON DELETE SET NULL. What happens if a user tries to delete a customer who has existing invoices?
The customer is deleted, and the CustomerID in the Invoices table is set to NULL
3 multiple choice options
A developer wants to ensure that every row in the Employees table has a value for the LastName column. Which constraint should be used?
NOT NULL
3 multiple choice options
To ensure that every employee has an exclusive email address, which constraint should be applied to the Email column?
UNIQUE
3 multiple choice options
A business rule states that the UnitPrice of a product must always be greater than zero. Which constraint is best suited to enforce this rule?
CHECK
3 multiple choice options
A Primary Key A constraint enforces certain rules on a column or set of columns. Which two constraints does it combine to enforce these rules?
UNIQUE and NOT NULL
3 multiple choice options
A developer needs to clear all data from a very large LogEvents table containing millions of rows. The table structure must remain, but all records should be removed. Which command is typically the most eƯicient for this specific task because it is a minimally logged operation?
TRUNCATE TABLE LogEvents;
3 multiple choice options
A developer needs to ensure that the combination of a FlightNumber and FlightDate is unique in the Flights table. How should this be implemented?
By adding a single UNIQUE table constraint on both (FlightNumber, FlightDate) columns
3 multiple choice options
A developer wants to give a name to a new constraint to make error messages more understandable. Which keyword allows this?
CONSTRAINT
3 multiple choice options
How would a developer remove a named constraint called PriceCheck from a Products table?
ALTER TABLE Products DROP CHECK PriceCheck;
3 multiple choice options
A developer adds a NOT NULL constraint to a PhoneNumber column in a table that already contains several rows with NULL phone numbers. What will happen when they try to apply this change?
The ALTER TABLE statement will fail
3 multiple choice options
A table Courses has a primary key CourseID. A table Prerequisites has a foreign key CourseID that references the Courses table. What must happen before the Courses table can be dropped?
The Prerequisites table must be dropped first
3 multiple choice options
A Departments table has a ManagerID and an AdminAssistID, both of which are foreign keys to the Employees table. Is this a valid table design?
Yes, this is a valid design
3 multiple choice options
Which SQL command is used to define the structure of a new table?
CREATE TABLE
3 multiple choice options
A business analyst wants to get a list of all products with a price less than $50. Which SQL clause is used to filter the rows based on this condition?
WHERE
3 multiple choice options
A Students table has a GPA column. The business rule states that the GPA must be between 0.0 and 4.0. Which constraint should be used to enforce this rule on the column?
CHECK (GPA >= 0.0 AND GPA <= 4.0)
3 multiple choice options
To store a 5-digit US ZIP code like '90210', which data type provides the most efficient and appropriate storage?
CHAR(5)
3 multiple choice options
A developer needs to add a new record for a product to the Products table, which has the columns ProductID, ProductName, and Price. Which of the following is the correct syntax to insert this new product?
INSERT INTO Products (ProductID, ProductName, Price) VALUES (101, 'Laptop', 1200.00);
3 multiple choice options
The price of a product with a ProductID of 205 needs to be changed to $49.99. Which statement correctly performs this update?
UPDATE Products SET Price = 49.99 WHERE ProductID = 205;
3 multiple choice options
To ensure that every product has a unique SKU (Stock Keeping Unit), a developer needs to add a constraint to the existing Products table. Which syntax correctly adds this table-level constraint?
ALTER TABLE Products ADD CONSTRAINT UQ_Product_SKU UNIQUE (SKU);
3 multiple choice options
According to standard operator precedence, which of the following operators is evaluated before AND but after comparison operators like = or >?
NOT
3 multiple choice options
What is the function of the unary - operator in SQL?
It reverses the sign of one numeric value.
3 multiple choice options