Câu hỏi về SQL
Quiz
•
Computers
•
11th Grade
•
Practice Problem
•
Easy
Nguyễn Anh
Used 1+ times
FREE Resource
Enhance your content in a minute
12 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Câu lệnh SQL nào dùng để kết hợp kết quả của hai truy vấn với điều kiện mỗi bản ghi chỉ xuất hiện một lần trong kết quả cuối cùng?
JOIN
UNION
INNER JOIN
INTERSECT
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Câu lệnh SQL nào dưới đây là đúng để chọn các bản ghi từ bảng employees với salary lớn hơn 5000 và theo thứ tự giảm dần của salary?
SELECT * FROM employees WHERE salary > 5000 ORDER BY salary ASC;
SELECT * FROM employees WHERE salary > 5000 ORDER BY salary DESC;
SELECT * FROM employees ORDER BY salary DESC WHERE salary > 5000;
SELECT * FROM employees ORDER BY salary ASC HAVING salary > 5000;
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Câu lệnh nào trong SQL dùng để chọn các bản ghi không có giá trị NULL?
SELECT * FROM students WHERE age IS NOT NULL;
SELECT * FROM students WHERE age != NULL;
SELECT * FROM students WHERE age = NULL;
SELECT * FROM students WHERE age <> NULL;
4.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Để tìm tất cả các bản ghi từ bảng students(id, ten, points) mà có điểm lớn hơn 8, câu lệnh SQL đúng là gì?
SELECT * FROM students WHERE points > 8;
SELECT * FROM students WHERE points = 8;
SELECT id, ten, points FROM students WHERE points > 8;
SELECT * FROM students HAVING points > 8;
5.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Bảng có các cột: hocsinh(ID, Name, diem)
Câu lệnh SQL để lấy tất cả các cột từ bảng học sinh: SELECT * FROM Table hocsinh;
Câu lệnh lọc ra những học sinh có điểm lớn hơn 8: SELECT * FROM hocsinh WHERE diem = 8;
Xoá một học sinh có mã (id) là 5 thì: DELETE FROM hocsinh WHERE ID=5;
Thêm một học sinh có mã (id) là 10 thì: INSERT hocsinh VALUES(10, 'Nguyễn Duy Anh', 9)
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Câu lệnh SQL nào dưới đây được sử dụng để lấy tất cả các cột từ bảng students?
SELECT * FROM students;
SELECT ALL FROM students;
SELECT columns FROM students;
SELECT students FROM *;
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Câu lệnh nào dưới đây được sử dụng để thay đổi giá trị của cột age cho tất cả các sinh viên có id = 1 trong bảng students?
UPDATE students SET age = 20 WHERE id = 1;
UPDATE students SET age = 20;
UPDATE students SET age = 20 WHERE id = 2;
UPDATE students WHERE id = 1 SET age = 20;
Create a free account and access millions of resources
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?
Similar Resources on Wayground
15 questions
Computer and Other Human Inventions
Quiz
•
University
17 questions
Security and Ethics
Quiz
•
9th - 12th Grade
10 questions
Data Warehouse - Foundations
Quiz
•
University
13 questions
INTERNET CONNECTION
Quiz
•
12th Grade
15 questions
GIS Unit III
Quiz
•
University
14 questions
BTEC National ICT U2 - Data Types and Validation
Quiz
•
12th Grade
15 questions
Problem Solving : Design Solution
Quiz
•
12th Grade
15 questions
Virtual Private Server
Quiz
•
12th Grade
Popular Resources on Wayground
10 questions
Honoring the Significance of Veterans Day
Interactive video
•
6th - 10th Grade
9 questions
FOREST Community of Caring
Lesson
•
1st - 5th Grade
10 questions
Exploring Veterans Day: Facts and Celebrations for Kids
Interactive video
•
6th - 10th Grade
19 questions
Veterans Day
Quiz
•
5th Grade
14 questions
General Technology Use Quiz
Quiz
•
8th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
15 questions
Circuits, Light Energy, and Forces
Quiz
•
5th Grade
19 questions
Thanksgiving Trivia
Quiz
•
6th Grade
