Books
Learn HTML
Learn CSS
Learn Git
Learn Javascript
Learn PHP
Learn python
Learn Java
Exercises
HTML
JavaScript
Git
CSS
PHP
Courses
Quizzes
Snippets
Tools
General Tools
Password Generator
HTML Editor
HTML Encoder
Base 64
Code Diff
JSON Beautifier
CSS Beautifier
Markdown Convertor
Find the Closest Tailwind CSS Color
Phrase encrypt / decrypt
Browser Feature Detection
CSS Maker
CSS Maker
CSS Maker text shadow
CSS Maker Text Rotation
CSS Maker Out Line
CSS Maker RGB Shadow
CSS Maker Transform
CSS Maker Font Face
Color Tools
Color Picker
Colors CMYK
Colors HWB
Colors HSL
Color Hex
Color mixer
Color Converter
Colors RGB
Color Contrast Analyzer
Color Gradient
String Tools
String Length Calculator
MD5 Hash Generator
Sha256 Hash Generator
String Reverse
URL Encoder
URL Decoder
Base 64 Encoder
Base 64 Decoder
Extra Spaces Remover
String to Lowercase
String to Uppercase
Word Count Calculator
Empty Lines Remover
HTML Tags Remover
Binary to Hex
Hex to Binary
Rot13 Transform on a String
String to Binary
Duplicate Lines Remover
Change theme
Dark
Light
System
Books
Learn HTML
Learn CSS
Learn Git
Learn Javascript
Learn PHP
Learn python
Learn Java
How To
How To NodeJs
How To Linux
How To AngularJs
How To PHP
How To HTML
How To CSS
How To Symfony
How To Git
How To Apache
How To JavaScript
How To Java
How To Vue.js
How To Python
SQL Basics
1/25
Which SQL statement is applied for updating data in a database?
UPDATE
SAVE AS
MODIFY
SAVE
Next >
2/25
Which SQL statement is used to delete data from a table?
TRUNCATE
DELETE
REMOVE
Next >
3/25
Which of the SQL statements below deletes all the rows in a table called PricesData?
DELETE ALL PricesData
DELETE PricesData
DELETE FROM PricesData
DELETE rows FROM PricesData
Next >
4/25
Can the SELECT clause list have a computed value like in the example below? SELECT CustomerName, UnitPrice * NumberofUnits FROM Sale.
No
Yes
Next >
5/25
How do you use a subquery to find names of customers who have placed orders in an 'Orders' table?
SELECT Name FROM Customers WHERE CustomerID IN (SELECT CustomerID FROM Orders)
SELECT CustomerID FROM Orders WHERE Name IN (SELECT Name FROM Customers)
SELECT Name FROM Customers WHERE EXISTS (SELECT CustomerID FROM Orders)
SELECT Name FROM Customers JOIN Orders ON Customers.CustomerID = Orders.CustomerID
Next >
6/25
How do you create an index on the 'EmployeeName' column of the 'Employees' table for faster queries?
CREATE INDEX ON Employees (EmployeeName)
INDEX Employees ADD EmployeeName
ADD INDEX EmployeeName ON Employees
CREATE Employees INDEX EmployeeName
Next >
7/25
What does the SQL statement 'BEGIN TRANSACTION' do?
Starts a new SQL transaction.
Creates a new table called TRANSACTION.
Begins a new subquery.
Starts a new index creation process.
Next >
8/25
How can you combine results from multiple SELECT statements in SQL?
USING UNION
WITH COMBINE
USING UNION ALL
USING JOIN
USING UNION or UNION ALL
Next >
9/25
What is the result of executing a SQL statement that includes a WHERE clause with a non-existent value?
An error message.
All records from the table.
No records (an empty result set).
The first record in the table.
Next >
10/25
What does the SQL clause 'LIMIT 10' do when added to a SELECT statement?
Limits the result to the first 10 rows.
Selects only the 10th row.
Limits each column to 10 characters.
Throws an error as 'LIMIT' is not a valid SQL clause.
Next >
11/25
In SQL, what does the 'BETWEEN' operator do?
Checks whether a value lies within a specified range.
Compares two values for equality.
Sorts the result set between two columns.
Divides the result set into two parts.
Next >
12/25
Which SQL function is used to return the current date and time?
GETDATE()
CURRENT_TIMESTAMP
NOW()
DATETIME()
TIMESTAMP()
Next >
13/25
Which SQL clause is used to filter the results of a GROUP BY operation?
FILTER BY
HAVING
WHERE
GROUP WHERE
Next >
14/25
What does the following SQL statement do: SELECT EmployeeName, SUM(Salary) OVER (PARTITION BY DepartmentID) FROM Employees?
Summarizes the total salary for each department
Displays an error as the syntax is incorrect
Displays the sum of salaries within each department for each employee
Calculates the overall sum of salaries in the Employees table
Next >
15/25
How do you delete a table named 'TemporaryData' only if it exists in the database?
DROP TABLE IF EXISTS TemporaryData
DELETE TABLE TemporaryData IF EXISTS
REMOVE TABLE TemporaryData WHEN EXISTS
DROP TABLE TemporaryData ONLY IF EXISTS
Next >
16/25
Which of the following is NOT a valid aggregate function in SQL?
SUM()
AVERAGE()
MAX()
COUNT()
Next >
17/25
What is the purpose of the SQL 'WITH' clause?
To provide a temporary name to a table or a set of columns
To define a temporary subquery block that can be used in a SELECT statement
To specify the conditions for a join
To initialize variables within an SQL query
Next >
18/25
Which SQL statement is used to change the data type of a column in an existing table?
ALTER TABLE table_name MODIFY column_name new_data_type
UPDATE TABLE table_name SET column_name TYPE new_data_type
CHANGE TABLE table_name column_name new_data_type
MODIFY TABLE table_name column_name SET TYPE new_data_type
Next >
19/25
Which statement correctly shows the use of an alias in SQL?
SELECT EmployeeID AS ID FROM Employees
SELECT EmployeeID RENAME ID FROM Employees
SELECT EmployeeID -> ID FROM Employees
SELECT EmployeeID NAME ID FROM Employees
Next >
20/25
How can you retrieve unique values from the column 'EmployeeName' of the 'Employees' table?
SELECT DISTINCT EmployeeName FROM Employees
SELECT UNIQUE EmployeeName FROM Employees
GET ALL UNIQUE EmployeeName FROM Employees
SELECT EmployeeName FROM Employees DISTINCT
Next >
21/25
Which of the following is a valid type of SQL join?
CROSS JOIN
REVERSE JOIN
OUTER JOIN
LINK JOIN
RIGHT JOIN
Next >
22/25
Which SQL statement is used to return only distinct (different) values?
SELECT UNIQUE column_name FROM table_name
SELECT DISTINCT column_name FROM table_name
SELECT DIFFERENT column_name FROM table_name
SELECT column_name FROM table_name DISTINCT
Next >
23/25
How do you select all records from a table named 'Customers' where the 'CustomerName' starts with 'A'?
SELECT * FROM Customers WHERE CustomerName LIKE 'A%'
SELECT * FROM Customers WHERE CustomerName = 'A*'
SELECT * FROM Customers WHERE CustomerName STARTS WITH 'A'
SELECT * FROM Customers WHERE CustomerName BEGINS WITH 'A'
Next >
24/25
In SQL, which command is used to add a new column to an existing table?
ADD COLUMN column_name TO table_name
INSERT COLUMN column_name INTO table_name
ALTER TABLE table_name ADD column_name column_type
UPDATE TABLE table_name SET ADD column_name column_type
Next >
25/25
How do you find the minimum value in a column named 'Price' from the 'Products' table?
SELECT MIN(Price) FROM Products
FIND MINIMUM(Price) IN Products
SELECT LOWEST(Price) FROM Products
GET MIN(Price) FROM Products
Next >
To get the result of the quiz, please provide your email address (optional)..
Get Certificate
It seems you haven't answered any questions yet. Please provide your answers to proceed.