STRUCTURED QUERY LANGUAGE TEST

Progress

1.

 What does a  DML Stand for?

2.

Which of the following is a valid SQL type?

3.

Which one is a non-relational database?

4.

To delete the database __________ Command is used

5.

SQL can be used to

6.

Find the name of these cities with temperature and condition whose condition is neither sunny nor cloudy

7.

Identify the average salary of the jobs 'MANAGER' and 'ANALYST'. Display job, average salary if the identified average salary is more than 1500.

8.

The _______ clause allows us to select only those rows in the result relation of the ____ clause that satisfy a specified predicate.

9.

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

10.

Select ________ dept_name from instructor; 

Here which of the following displays the unique values of the column?

11.

Analyze the following Query and Mark the answer whether it's the correct query or not ?

select deptName
from Employee
having avg (salary)
group by deptName
where sex = 'M'

12.

Which of the following query is correct for selecting the name of the staff from ''staffinfo'' table where salary is 10000 or 25000?

13.

The SQL WHERE clause used for 

14.

The HAVING clause does which of the following?

15.

Which SQL Query is used for updating the ContactName in the Customers table?

16.

What is the meaning of the “ORDER BY” clause in MySQL?

17.

What can be the condition in the "WHERE" clause in a SQL query?

18.

Select ID, name, dept name, salary * 1.1 where instructor;

The query given below will not give an error. Which one of the following has to be replaced to get the desired output?

19.

You can delete a view with _____________ Command.

20.

With SQL, how can you return all the records from a table named "Persons" sorted descending by "FirstName"?

21.

If you don't specify ASC or DESC after a SQL ORDER BY clause, the following is used by default

22.

Analyse the following Query and Mark the answer whether it's the correct query or not?

SELECT Name, Age, Firstname, Lastname
FROM EMPLOYEE     
GROUP BY NAME, SALARY;  

23.

Which command is used to change the definition of a table in SQL ?

24.

How to create index idx_pname for multiple columns (Lastname, Firstname) in a Person table?

25.

Can you validate the statement?

"ORDER BY" can only be used by WHERE Clause.

True or False?

26.

Which of the SQL statement is correct?

27.

Which syntax is used for Drop Index (idx_pname) from the Person table in MYSQL?

28.

Select ID, GPA from student grades order by GPA ____________.

In order to give only 10 ranks, on the whole, we should use.

29.

Select two options which do not belong to the Purpose of Delete

30.

Find all the cities whose humidity is 89

31.

A subquery in an SQL SELECT statement is enclosed in

32.

Where subqueries can not be used?

33.

Which of the following multi-row operators can be used with a sub-query?

34.

What is "Subquery"?

35.

Which of the following is true about sub-queries?

36.

Which one of the following is a set of one or more attributes taken collectively to uniquely identify a record?

37.

Which of the following do you need to consider when you make a table in SQL?

38.

Can you validate the statement?

We can use the index on columns that contain a high number of NULL values.

True or False?

39.

Which one of the following can be taken as a Primary Key?

40.

By default, which key creates Clustered index?

41.

Analyze the following tables and output and choose the correct query to achieve the output.

42.

 In which two cases would you use an outer join? (Choose two.)

43.

Analyze the following tables and output and choose the correct query to achieve the output.

 

44.

What is the syntax for joining two tables? Pick Two

45.

Choose the correct query for the below scenario.

 

46.

Statement: Join for each row of one table to every row of another table.

Which Join?

47.

Analyze the following tables and output and choose the correct query to achieve the output.

48.

Choose the query that matches the above image.

49.

Which type of join is not desirable for retrieval?

50.

Where are Joins used?

51.

Use below table (Salesemployee) and answer the following question
What is the output of following query ?
SELECT MAX(Salary) from Salesemployee 
WHERE Employee_ID % 2 = 0 ;  

 

52.

Use below table (Salesemployee) and answer the following question
What is the output of following query ?
SELECT AVG(Salary) from Salesemployee 
where Dept = ' HR';    

 

53.

Use below table (Salesemployee) and answer the following question
What is the output of following query ?
SELECT Max(Salary) from Salesemployee 
WHERE Gender = 'Male';  

 

54.

Use below table (Salesemployee) and answer the following question
What is the output of following query ?
SELECT Count(Salary) from Salesemployee 
where name Like 'S%' and Dept ='HR';

 

55.

What values does the count(*) function ignore?

56.

Use below table (Salesemployee) and answer the following question
What is the output of following query ?
SELECT AVG(Salary) from Salesemployee 
WHERE Gender = 'Female';  

 

57.

Use below table (Salesemployee) and answer the following question
What is the output of following query ?
SELECT Count(*) from Salesemployee 
WHERE Salary >=500 and Dept = 'Sales';

 

58.

Use below table (Salesemployee) and answer the following question
What is the output of following query?
SELECT MIN(Salary) from Salesemployee 
WHERE Gender = 'Female';  

 

59.

Use below table (Salesemployee) and answer the following question
What is the output of following query ?
SELECT Count(*) from Salesemployee 
WHERE Salary >=500 and Dept = 'Marketing';

 

60.

Use below table (Salesemployee) and answer the following question
What is the output of following query ?
SELECT Count(*) from Salesemployee 
WHERE Salary >500;  

 

Assessment complete! Thank you for you time.
We are redirecting you to the result page, Please click on 'SUBMIT'