Online Exam Quiz

questionQuestion  1 to 30

What does the SQL LIKE operator do?

  • Matches a pattern
  • Selects columns
  • Selects records if all conditions are met
  • Inserts data into a table
Mark for review

What is the result of the SQL statement SELECT 10 / 2;?

  • 2
  • 5
  • 10
  • 20
Mark for review

What is the purpose of the SQL IS NULL operator?

  • Filters rows that are null
  • Filters rows that are not null
  • Filters columns that are null
  • Filters columns that are not null
Mark for review

Which SQL function is used to round a number to the nearest integer?

  • ROUND()
  • FLOOR()
  • CEIL()
  • TRUNCATE()
Mark for review

What is the purpose of the SQL COALESCE function?

  • Returns the first non-null value
  • Counts non-null values
  • Returns the sum of values
  • Returns the last non-null value
Mark for review

What is a foreign key in SQL?

  • A unique identifier for a record
  • A duplicate identifier for a record
  • A primary key in another table
  • A key to foreign data
Mark for review

Which SQL keyword is used to remove duplicate records from a result set?

  • UNIQUE
  • DISTINCT
  • DIFFERENT
  • DELETE DUPLICATES
Mark for review

What is the SQL command to create a view?

  • CREATE VIEW
  • ADD VIEW
  • NEW VIEW
  • MAKE VIEW
Mark for review

Which SQL statement is used to extract data from multiple tables?

  • SELECT FROM
  • SELECT JOIN
  • SELECT MERGE
  • SELECT UNION
Mark for review

Which SQL function is used to count the number of rows in a query?

  • COUNT()
  • SUM()
  • TOTAL()
  • NUMBER()
Mark for review

Which SQL keyword is used to create a relationship between tables?

  • RELATE
  • LINK
  • CONNECT
  • JOIN
Mark for review

What is a JOIN in SQL?

  • Combining data from multiple tables
  • Summing up data
  • Filtering data
  • Sorting data
Mark for review

What does the SQL MIN() function do?

  • Returns the maximum value
  • Returns the minimum value
  • Returns the average value
  • Returns the sum of values
Mark for review

Which SQL statement is used to return only different values?

  • SELECT DIFFERENT
  • SELECT UNIQUE
  • SELECT DISTINCT
  • SELECT VARIOUS
Mark for review

Which SQL function returns the current date?

  • NOW()
  • CURRENT_DATE()
  • GETDATE()
  • SYSDATE()
Mark for review

Which SQL command is used to change data in an existing record?

  • MODIFY
  • CHANGE
  • UPDATE
  • SAVE
Mark for review

Which SQL statement is used to delete data from a database?

  • REMOVE
  • DELETE
  • CLEAR
  • ERASE
Mark for review

Which SQL keyword is used to sort the result-set?

  • ORDER
  • SORT
  • ARRANGE
  • GROUP
Mark for review

Which command is used to remove a table and all its data from the database?

  • DROP TABLE
  • DELETE TABLE
  • ERASE TABLE
  • CLEAR TABLE
Mark for review

What is the result of the SQL statement SELECT 2 + 3;?

  • 2
  • 5
  • 23
  • Error
Mark for review

Which SQL statement is used to remove privileges from a user?

  • REMOVE
  • REVOKE
  • DELETE PRIVILEGE
  • DISALLOW
Mark for review

Which SQL function is used to count non-NULL values in a column?

  • COUNT()
  • COUNT(*)
  • COUNT(column)
  • COUNT NOT NULL
Mark for review

Which SQL keyword is used to combine two result sets?

  • UNION
  • JOIN
  • MERGE
  • COMBINE
Mark for review

What is the default sorting order in SQL?

  • Ascending
  • Descending
  • Random
  • None
Mark for review

Which SQL keyword is used to add a new column to an existing table?

  • ADD COLUMN
  • NEW COLUMN
  • INSERT COLUMN
  • ALTER TABLE ADD
Mark for review

What does the SQL CASE statement do?

  • Switches the result set based on a condition
  • Joins tables
  • Groups data
  • Sorts data
Mark for review

Which SQL statement is used to create an index?

  • CREATE INDEX
  • ADD INDEX
  • NEW INDEX
  • MAKE INDEX
Mark for review

How do you select all columns from a table named "Orders"?

  • SELECT all FROM Orders
  • SELECT * FROM Orders
  • SELECT Orders
  • SELECT all_columns FROM Orders
Mark for review

Which SQL clause is used to specify the condition for grouping rows?

  • GROUP BY
  • ORDER BY
  • HAVING
  • WHERE
Mark for review

How do you select all the columns from a table named "Users"?

  • SELECT all FROM Users
  • SELECT * FROM Users
  • SELECT Users
  • SELECT all_columns FROM Users
Mark for review

blinkerOnline

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • Answered
  • Not Answered
  • Marked for Review