No student devices needed. Know more
30 questions
which of the following is not an aggregate function in SQL?
SUM
AVG
COUNT
FIND
Which of the following is true about NULL values in SQL?
A NULL value means zero.
A null value can only be used with numeric attributes.
Null value just means that data of that attribute is not available.
None of these.
Which of the following is not a Clause in SQL?
Below
Limit
Where
Group By
How many Primary keys can be created on a table?
Infinity
2
1
24
Which of the following operator is used to extract pattern matching data from the database?
LIKE
SELECT
FIND
UPDATE
SQL database follows which of the following principles?
ACID
AGILE
SQL
DBMS
Which of the following query finds employees with an experience more than 5?
Select * From DataFlair where experience>5;
Select * From DataFlair;
Select * From DataFlair where experience>=5;
Select * From DataFlair where experience<=5;
Which of the following shows comment in SQL?
/* This is a comment. */
# This is a comment.
% This is a comment. %
& This is a comment.
hich of the following statements about the MAX function in SQL are true?
Can be used on any datatype.
Returns the max value of the attribute.
It is an aggregate function.
All of the above statements are true.
Which of the following clause allows us to extract data in a range?
Between
Range
Find In
Like
Which of the following is not true about SQL Subqueries?
They are nested queries.
Subqueries are executed first.
Only one subquery can be nested.
None of these.
Which of the following is used to modify the data stored in the database?
SELECT
INSERT INTO
UPDATE
LIMIT
Which of the following is not a part of CRUD operations in SQL?
Creating a table.
Deleting records from the table.
Creating a copy of a table.
Updating the data stored in the table.
Which of the following query would limit the output to 5 rows?
SELECT * FROM DF 5;
SELECT * FROM DF LIMIT 5;
SELECT * FROM DF 5 LIMIT;
SELECT LIMIT(5) * FROM DF ;
Which of the following is true about the RDBMS?
RDBMS stands for the Relational Database Management System.
RDBMS is mandatory to use to create a database.
Both a and b.
None of these.
What is the full form of SQL?
Structured Query Language
Structured Question Language
Structural Query Language
Structuring Query Language
Which of the following is not a data type in SQL?
int
Varchar
Image
blob
Which keyword allows us to find the unique values in the database?
DIFF
UNIQUE
FIND
DISTINCT
We can’t use subqueries with which of the clauses given below?
SELECT
UPDATE
DELETE
None of these
Write a query to draw out details of all the employees whose name starts with ‘A’ or are based in Pune.
SELECT * DataFlair WHERE name location = 'Pune';
SELECT * FROM DataFlair WHERE name LIKE '%A__' or location = 'Pune';
SELECT * FROM DataFlair WHERE name LIKE 'A%' or location = 'Pune';
None of the above.
Which of the queries below can be used to alter the DataFlair table such that we can add a new gender column to our table?
ALTER TABLE DataFlair ADD gender varchar;
ALTER TABLE DataFlair gender varchar(10);
ALTER DataFlair ADD gender varchar;
ALTER TABLE DataFlair ADD gender varchar(10);
Which of the following query if run will Truncate the DataFlair table?
TRUNCATE DataFlair;
TRUNCATE TABLE DataFlair;
TRUNCATE TABLE;
None of these
Which all languages support the integration of SQL with them?
Java
C++
Python
All of these
What is the difference if we truncate a table and if we drop a table?
In both cases, the table is deleted.
In both cases, the data is deleted.
In truncate, the data is deleted and in drop the whole table is deleted.
In truncate, the table is deleted while when the table is dropped the data is deleted.
Which of the following query returns the results in ascending order of the experience column?
SELECT experience, name FROM DataFlair;
SELECT name, experience FROM DataFlair;
SELECT name, experience FROM DataFlair Order By name ASC;
SELECT experience, name FROM DataFlair Order By experience ASC;
Which of the query below is likely to run into an error?
SELECT FROM DataFlair;
SELECT name, emp_id FROM DataFlair
SELECT name FROM DataFlair;
SELECT * FROM DataFlair;
Which of the below queries results have only 10 rows being shown in the result displayed?
SELECT * FROM DataFlair;
SELECT name,emp_id FROM DataFlair Display 10;
Select name, location from DataFlair LIMIT 10;
Select Count(name) FROM DataFlair;
Which of the below Query can be used to set the new Auto – increment value to 500 in our table.
Update DataFlair AutoIncrement = 500;
ALTER TABLE DataFlair AUTO_INCREMENT = 500 ;
ALTER DataFlair TABLE Auto_Increment = 500;
ALTER DataFlair Increment_value = 500;
Which of the following returns the average value of any numeric column in SQL?
Average function
AVG() function
Average_Value function
None of these
hat is the one thing we need to pay attention to when we need to use constraints?
Can be used with both Insert and Delete.
Can be used with only Insert.
Can only be used with the Create clause.
Can be used with Create, Insert and Delete.
Explore all questions with a free account