M12 - SQL Query

M12 - SQL Query

University

10 Qs

quiz-placeholder

Similar activities

Gk Marathon-11 Quiz

Gk Marathon-11 Quiz

10th Grade - Professional Development

15 Qs

aj quizzzzzzz

aj quizzzzzzz

KG - University

10 Qs

Lesson Review _ Unit 1: Our World

Lesson Review _ Unit 1: Our World

University

10 Qs

Pendakian Taman Nasional Bromo Tengger Semeru

Pendakian Taman Nasional Bromo Tengger Semeru

KG - University

10 Qs

USA Studies Weekly week 8

USA Studies Weekly week 8

5th Grade - University

15 Qs

Japan: WitWiCS Round 2

Japan: WitWiCS Round 2

KG - University

10 Qs

Indian River

Indian River

University

10 Qs

Trivia

Trivia

2nd Grade - University

10 Qs

M12 - SQL Query

M12 - SQL Query

Assessment

Quiz

Geography

University

Practice Problem

Easy

Created by

ALI SUROJAYA

Used 3+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

10 questions

Show all answers

1.

FILL IN THE BLANK QUESTION

30 sec • 1 pt

To find the average salary for each department, you would use the following SQL query:

SELECT Department, AVG(Salary)
FROM Employees
GROUP BY _____;

2.

FILL IN THE BLANK QUESTION

30 sec • 1 pt

To get students who have a GPA greater than 3.5 and are majoring in 'Engineering', you would use the following SQL query:

SELECT *

FROM Students

WHERE GPA > 3.5 ___ Major = 'Engineering';

3.

FILL IN THE BLANK QUESTION

30 sec • 1 pt

To find the maximum order amount for each customer, you would use the following SQL query:
SELECT CustomerID, MAX(OrderAmount)

FROM Orders

GROUP BY _____;

4.

FILL IN THE BLANK QUESTION

30 sec • 1 pt

Retrieve employee names and their corresponding department names from the employees and departments tables:

SELECT employees.name, departments.department_name

FROM employees

_____ departments

ON employees.department_id = departments.id;

5.

FILL IN THE BLANK QUESTION

30 sec • 1 pt

Find the total number of hours worked by each employee from the timesheets table:

SELECT employee_id, _____(hours) AS total_hours_worked

FROM timesheets

GROUP BY employee_id;

6.

FILL IN THE BLANK QUESTION

30 sec • 1 pt

Retrieve the name and highest score of students from the scores table:

SELECT name, _____(score) FROM scores;

7.

FILL IN THE BLANK QUESTION

30 sec • 1 pt

List all employees and their respective managers' names from the employees table (assuming the table has a manager_id field):

SELECT e1.name AS employee_name, e2.name AS manager_name

FROM employees e1 _____ employees e2 ON e1.manager_id = e2.id;

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?