NEW
Font size
WorksheetsINFOMANAGEMENT MIDTERM
Total questions: 60
Worksheet time: 30mins
A database is an organized collection of data. In an RDBMS, which part represents the attributes (fields) of the data?
Rows
Primary Keys
Columns
Relationships
Which characteristic of MySQL specifically refers to its ability to handle increasing amounts of data and high-traffic demands without sacrificing performance?
Open-Source
SQL-based
Scalable
Cross-Platform
In the XAMPP acronym, what does the "X" signify regarding the software’s compatibility?
It is an eXtended version of the original LAMP stack.
It is designed exclusively for the Windows "X" operating system.
it is Cross-Platform, supporting Windows, macOS, and Linux.
It indicates that the database uses XML for data storage.
SQL is described as a "standardized programming language."
For which specific purpose was it engineered?
Designing the User Interface (UI) of web applications.
Managing and manipulating relational databases.
Compiling operating system kernels like Linux.
Scripting the client-side behavior of web browsers.
Which of the following is a mandatory requirement for every column created within a MySQL database table?
A Foreign Key and a Default Value.
A Name and a Data Type.
An Auto-increment value and a Comment.
A Primary Key and an Encryption Key.
In the structural hierarchy of a database table, "Rows" are best defined as:
Individual records or entries within the table.
The attributes that define the data category.
The links that connect two separate tables.
The SQL commands used to delete information.
Why is MySQL’s "Open-Source" nature considered an advantage for BSIT developers?
It is completely managed by a single corporation with no external input.
It allows anyone on the internet to view the developer's private data.
It does not require an operating system to function.
It is freely available for use and modification with community support.
To allow a developer to test a database-driven web application locally using XAMPP, which two modules must be active in the Control Panel?
FileZilla and Mercury
Tomcat and Apache
Apache and MySQL
PHP and Perl
Which of the following best describes the "Relational" aspect of MySQL?
All data is stored in a flat file with no connections.
Data is organized into tables that can be linked based on common data.
It only allows data to be stored if it is related to the user's login.
It refers to the relationship between the hardware and the software
If a developer needs to store currency values or financial records in a MySQL table, which data type mentioned in the Week 1 curriculum would be most appropriate?
Binary
Money
Character
Integer
In the architectural hierarchy of SQL, Data Definition Language (DDL) is frequently described as the "blueprint." What is the technical implication of this analogy?
DDL handles the encryption and security of the data rows.
DDL defines and manages the structure of database objects rather than the data itself.
DDL is used to perform complex mathematical calculations on stored integers.
DDL manages the connection between the web server and the database engine.
What is the most critical technical risk associated with the DROP DATABASE command?
It only deletes the tables but keeps the database structure intact.
It requires a manual restart of the Apache module in XAMPP.
It results in the complete and permanent loss of all information and structures within that database.
It prevents the creation of any new databases for a 24-hour period.
When executing a CREATE DATABASE testDB; command, what is the primary prerequisite for the SQL engine to successfully complete the operation?
The database name must be written in lowercase only.
The database engine must verify that no other database with the exact same name exists.
A table must be defined immediately within the statement.
The system must be in "Read-Only" mode.
In the context of the tblStudent example, what is the specific function of the NOT NULL constraint applied to the studID column?
It ensures the ID is automatically generated by the system.
It guarantees that the column cannot contain empty or missing values.
It allows the column to accept alphanumeric characters.
It prevents the column from being modified by an ALTER statement.
A table is defined with a Primary Key. According to the standard rules of RDBMS, which of the following statements regarding the Primary Key is true?
A table can have multiple Primary Keys to ensure redundancy.
The Primary Key column is allowed to contain NULL values if the table is empty.
A table can have only one Primary Key, and it must contain unique values.
The Primary Key must always be a VARCHAR data type.
You need to remove all student records from tblStudent to clear the database for a new semester, but you must keep the table structure (columns and data types) for future use. Which command is technically correct?
DROP TABLE tblStudent;
DELETE DATABASE tblStudent;
TRUNCATE TABLE tblStudent;
ALTER TABLE tblStudent DROP ALL;
Which clause is used in conjunction with ALTER TABLE to add a new attribute, such as email, to an existing table?
INSERT COLUMN
ADD
CREATE
UPDATE
If a developer needs to change the data type of an existing column named address from VARCHAR(30) to VARCHAR(100), which ALTER TABLE sub-command is required?
CHANGE COLUMN
MODIFY COLUMN
UPDATE TYPE
REPLACE DATA
What occurs physically to the data when the command DROP TABLE tblStudent; is executed?
The data is moved to a temporary backup folder.
The data remains, but the column headers are hidden.
The table structure and all data records within it are permanently deleted.
The table is renamed to "Deleted_tblStudent."
In a CREATE TABLE statement, the AUTO_INCREMENT keyword is commonly used for Primary Keys. What is its primary purpose?
To automatically encrypt the ID for security.
To generate a unique number automatically whenever a new record is inserted.
To prevent the table from growing too large in size.
To link the table to another database automatically.
Which of the following commands is NOT considered a part of the Data Definition Language (DDL) subset?
ALTER
CREATE
SELECT
DROP
Analyze the following syntax: ALTER TABLE tblStudent DROP COLUMN email;. What is the result of this operation?
It deletes the specific email address of a single student.
It removes the entire email column and all its associated data from the table structure.
It clears the data in the email column but keeps the column header.
It renames the column to "DROP."
Why must a developer be "careful" before executing a DROP command compared to a TRUNCATE command?
DROP is faster than TRUNCATE.
DROP removes the "container" (table/database), while TRUNCATE only removes the "content."
TRUNCATE deletes the database, while DROP only deletes a row.
There is no technical difference between the two.
Which of these is the correct syntax to create a database named 'University'?
MAKE DATABASE University;
NEW DATABASE University;
CREATE DATABASE University;
DATABASE CREATE University;
Data Manipulation Language (DML) is distinct from Data Definition Language (DDL). Which of the following best describes the primary objective of DML commands in MySQL?
To create, modify, and remove the schema and table structures.
To manage and interact with the actual data records stored within tables.
To define the data types and constraints of specific columns.
To configure the physical storage settings of the database engine.
When executing a SELECT statement, where is the retrieved data technically held before being displayed to the user?
In a permanent secondary table within the database.
In a temporary "result-set" or result table.
Within the system’s BIOS configuration.
In the CREATE TABLE log file.
In the command SELECT FROM tblStudInfo;, what is the technical implication of the wildcard () symbol?
It instructs the engine to find records that contain errors.
It acts as a placeholder for a specific, unknown record ID.
It indicates that all columns from the specified table should be returned.
It filters the data to show only the primary key column.
You are tasked with adding a new student to tblStudInfo. Which DML command is specifically engineered for adding new rows of data?
ADD RECORD
INSERT INTO
CREATE ROW
UPDATE NEW
A developer executes the following: UPDATE tblStudInfo SET lastName = 'Reyes';. If there are 500 records in the table, what is the result of this operation?
Only the first record in the table will have its last name changed to 'Reyes'.
The command will fail because no Primary Key was specified.
Every single record in the table will have its last name updated to 'Reyes'.
Only the records that currently have a NULL last name will be updated.
Why is the WHERE clause considered the most critical component of an UPDATE or DELETE operation in a production environment?
It is the only way to specify which data type the column should use.
It defines which specific records should be affected, preventing accidental mass data loss or modification.
It speeds up the database by compressing the data before the change.
It is required by the SQL engine to identify the name of the table.
Which of the following is the correct syntax for updating a student's address based on their unique identification number?
UPDATE tblStudInfo WHERE studID = 10 SET address = 'Manila';
CHANGE tblStudInfo SET address = 'Manila' WHERE studID = 10;
UPDATE tblStudInfo SET address = 'Manila' WHERE studID = 10;
MODIFY tblStudInfo SET address = 'Manila' WHERE studID = 10;
When deleting a specific record, such as "Juan Dela Cruz" with a studID of 12, why is it standard practice to use the Primary Key in the WHERE clause rather than the name?
Using the name is restricted by MySQL security protocols.
Names are not unique; using the Primary Key ensures that only the specific intended record is deleted.
The DELETE command does not recognize string/character data types.
Primary Keys are automatically deleted faster by the CPU.
If you omit the WHERE clause in a DELETE FROM tblStudInfo; statement, what happens to the table structure itself?
In the context of the SELECT statement, how does a developer retrieve only the firstName and lastName columns without pulling all other attributes?
SELECT (firstName, lastName) FROM tblStudInfo;
SELECT firstName, lastName FROM tblStudInfo;
SELECT * FROM tblStudInfo WHERE columns = 'firstName, lastName';
GET firstName, lastName FROM tblStudInfo;
Which of the following commands is used to remove existing records from a table?
DROP
TRUNCATE
REMOVE
DELETE
Analyze this command: DELETE FROM tblStudInfo WHERE lastName = 'Dela Cruz';. If multiple students share the last name 'Dela Cruz', how many will be removed?
Only the one with the lowest Primary Key value.
Only the most recently added record.
All records where the last name matches 'Dela Cruz'.
None; the command will fail because names are not unique.
Which DML command is used to retrieve data but does not modify the data stored on the disk?
UPDATE
INSERT INTO
SELECT
DELETE
What is the logical difference between DELETE and DROP?
DELETE is DDL; DROP is DML.
DELETE removes records (data); DROP removes the entire table or database (structure).
DELETE is used for databases; DROP is used for rows.
There is no difference; they are synonymous in MySQL.
Which keyword in an UPDATE statement is used to specify the new values for the columns being modified?
CHANGE
SET
VALUES
INTO
When using the WHERE clause to filter data, which of the following best describes the underlying technical process performed by the SQL engine?
It reorders the physical storage of the table to match the query.
It evaluates each row against a specific boolean condition and extracts only those that return TRUE.
It deletes the rows that do not match the criteria from the temporary memory.
It creates a new permanent table containing only the filtered results.
You are writing a query to find students who live in 'Manila' AND are enrolled in the 'BSIT' course. What is the logical requirement for a record to be displayed in the result-set?
A. The record is displayed if either the city is Manila or the course is BSIT.
The record is displayed only if both conditions—living in Manila and being in BSIT—are simultaneously true.
The record is displayed if the student does not live in Manila but is in BSIT.
The record is displayed regardless of the course, as long as the city is Manila.
In a scenario where a registrar needs a list of students who are either from 'Quezon City' OR 'Dasmariñas', how will the OR operator handle a student who lives in 'Cavite'?
It will display the record because 'Cavite' is a neighboring city.
It will exclude the record because it does not satisfy at least one of the specified conditions.
It will display the record but mark the city as "Unknown."
It will throw a syntax error because the OR operator only works for numeric values.
Which operator would you utilize if you wanted to retrieve all student records except for those whose status is 'Dropped'?
AND
BETWEEN
NOT
EXCLUDE
A web developer needs to implement a "Top 5 Highest Scores" feature on a leaderboard. Which clause is most efficient for restricting the number of records returned to exactly five?
WHERE
OFFSET
LIMIT
SET
Data Definition Language (DDL) is considered the "blueprint" of a database because it focuses exclusively on defining the containers (schemas, tables, columns) rather than managing the records stored within them.
True
False
When a developer executes the DROP DATABASE command, the database engine removes the database name but maintains a temporary hidden backup of the information until the server is restarted.
True
False
In a MySQL table, a Primary Key is technically allowed to contain NULL values provided that all other entries in that specific column remain unique and non-repeating.
True
False
The TRUNCATE TABLE statement is a structural command that deletes both the data records and the table’s column definitions, effectively performing the same action as DROP TABLE.
True
False
If you need to change the data type of an existing column, such as converting a VARCHAR(30) to a TEXT type, the MODIFY keyword must be used within an ALTER TABLE statement.
True
False
The AUTO_INCREMENT attribute is primarily used to ensure that the database engine automatically generates a unique numerical sequence for a column, typically the Primary Key.
True
False
According to the fundamental syntax rules for the CREATE TABLE statement, every column defined must be assigned both a unique name and a specific data type.
True
False
A single MySQL table is architecturally capable of supporting multiple Primary Keys to allow for more complex data relationships within the same container.
True
False
Using the ALTER TABLE command with the ADD clause allows a developer to integrate a new column into a table without deleting or corrupting the data currently stored in the existing columns.
True
False
Data Definition Language (DDL) includes commands such as CREATE, ALTER, and DROP, while commands like INSERT and UPDATE are categorized under Data Manipulation Language (DML).
True
False
Data Manipulation Language (DML) is technically responsible for defining the schema and the data types of columns within a MySQL database.
True
False
When a SELECT statement is executed, the data is returned and stored in a temporary table structure known as a result-set.
True
False
The use of the wildcard asterisk (*) in a SELECT statement instructs the SQL engine to retrieve only the Primary Key and the first column of the specified table.
True
False
In MySQL, the INSERT INTO statement is specifically used to add new records to a table, but it cannot be used to modify existing data.
True
False
If a developer executes an UPDATE statement and accidentally omits the WHERE clause, the MySQL engine will automatically abort the operation to prevent data loss.
True
False
To ensure precision and avoid accidental mass updates, it is standard industry practice to use the Primary Key as the identifier within a WHERE clause.
True
False
