Search Header Logo

SQL Basics Quiz

Authored by VEDANT VEDANT

Other

University

Used 2+ times

SQL Basics Quiz
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of the SELECT statement in SQL?

To update data in a database table.

To delete data from a database table.

To create a new database table.

To retrieve data from a database table.

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Write a SQL query to select all columns from a table named 'Customers'.

SELECT ALL FROM Customers

SELECT * Customers

SELECT Customers FROM *

SELECT * FROM Customers

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Write a SQL query to insert a new record into a table named 'Employees' with columns 'Name' and 'Age'.

INSERT INTO Employees (Name, Age) VALUES ('Jane Smith', 30)

INSERT INTO Employees (Name, Age) VALUES ('John Doe', 25)

INSERT INTO Employees (Name, Age) VALUES ('Bob Johnson', 20)

INSERT INTO Employees (Name, Age) VALUES ('Mary Brown', 35)

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of the following SQL query: SELECT COUNT(*) FROM Orders;

The result of the query is the average of all values in the 'Orders' table.

The result of the query is the count of all rows in the 'Orders' table.

The result of the query is the maximum value in the 'Orders' table.

The result of the query is the sum of all values in the 'Orders' table.

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Write a SQL query to select only the 'Name' column from a table named 'Products'.

SELECT Name FROM Products;

SELECT ColumnName FROM Products;

SELECT ProductName FROM Products;

SELECT * FROM Products;

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Write a SQL query to insert multiple records into a table named 'Students' with columns 'Name' and 'Grade'.

INSERT INTO Students (Name, Grade) VALUES ('John', 'A'), ('Jane', 'B'), ('Mike', 'C', 'D')

INSERT INTO Students (Name, Grade) VALUES ('John', 'A'), ('Jane', 'B'), ('Mike', 'C', 'D', 'E')

INSERT INTO Students (Name, Grade) VALUES ('John', 'A'), ('Jane', 'B'), ('Mike', 'C', 'D', 'E', 'F')

INSERT INTO Students (Name, Grade) VALUES ('John', 'A'), ('Jane', 'B'), ('Mike', 'C')

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of the following SQL query: SELECT AVG(Price) FROM Products;

The result of the SQL query will be the average price of the products.

The result of the SQL query will be the sum of the prices of the products.

The result of the SQL query will be the maximum price of the products.

The result of the SQL query will be the minimum price of the products.

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?