
Mastering Basic SQL Commands

Quiz
•
Computers
•
10th Grade
•
Medium
Mrs Milliner
Used 20+ times
FREE Resource
14 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which SQL statement is used to update the `age` of a student named 'Alice' in the `students` table to 16?
UPDATE students SET age = 16 WHERE name = 'Alice'
UPDATE students age = 16 WHERE name = 'Alice'
SET age = 16 WHERE name = 'Alice' IN students
MODIFY students SET age = 16 WHERE name = 'Alice'
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How do you delete a record from the `students` table where the `name` is 'Bob'?
DELETE FROM students WHERE name = 'Bob'
REMOVE FROM students WHERE name = 'Bob'
DELETE students WHERE name = 'Bob'
DELETE FROM students name = 'Bob'
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct syntax to update the `grade` to 'A' for all students in the `students` table who are 15 years old?
UPDATE students SET grade = 'A' WHERE age = 15
UPDATE students grade = 'A' WHERE age = 15
SET grade = 'A' WHERE age = 15 IN students
MODIFY students SET grade = 'A' WHERE age = 15
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will happen if you try to delete a record from the `students` table without a WHERE clause?
It will delete all records from the table.
It will delete the first record from the table.
It will return an error.
It will delete no records.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following statements will correctly update the `name` of a student with `id` 3 to 'David'?
UPDATE students SET name = 'David' WHERE id = 3
UPDATE students name = 'David' WHERE id = 3
SET name = 'David' WHERE id = 3 IN students
MODIFY students SET name = 'David' WHERE id = 3
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How do you delete all students who have a NULL value in the `age` column?
DELETE FROM students WHERE age IS NULL
DELETE FROM students WHERE age = NULL
DELETE FROM students WHERE age EQUALS NULL
DELETE FROM students WHERE age NULL
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the result of the following SQL statement? `SELECT * FROM students WHERE age IS NOT NULL;`
It returns all rows with non-NULL `age` values.
It returns all rows with NULL `age` values.
It returns an error.
It returns all rows.
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
SQL and databases

Quiz
•
KG - 12th Grade
9 questions
Intermediate python

Quiz
•
9th - 12th Grade
10 questions
Bitmap & Vector Graphics

Quiz
•
8th - 11th Grade
10 questions
Photoshop Layers Review

Quiz
•
9th - 12th Grade
15 questions
Basic Microsoft Word

Quiz
•
1st Grade - Professio...
14 questions
Smishing Phishing Vishing Pharming

Quiz
•
10th Grade
13 questions
Word տեքստային խմբագրիչ 10-դասարան

Quiz
•
10th Grade
12 questions
2.3 Extracting information

Quiz
•
10th Grade - University
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
10 questions
UPDATED FOREST Kindness 9-22

Lesson
•
9th - 12th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
20 questions
US Constitution Quiz

Quiz
•
11th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Computers
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
20 questions
Analog vs Digital

Quiz
•
9th - 12th Grade
10 questions
Exploring Cybersecurity Techniques and Threats

Interactive video
•
6th - 10th Grade
10 questions
Understanding the Internet and Data Transmission

Interactive video
•
7th - 12th Grade