Header Ads Widget

Trending

6/recent/ticker-posts

SQL interview Questions and Answers

 SQL Interview Questions

Here is a list of SQL interview questions asked in Top MNCs. SQL is the most widely used Relational database language. With this article, you will know all frequently asked SQL interview questions. You can clear all concepts with these Top SQL Interview Questions. Get Prepared for your interview with the best and selected questions asked in the SQL interview. These are the Complex SQL interview questions.


List of SQL Interview Questions

  1. What is SQL?
  2.  What are the advantages of SQL?
  3.  What are the Uses of SQL?
  4.  What is the disadvantage of SQL?
  5. What are SQL data Types?
  6. What is the difference between SQL and MySQL?
  7. What is Database?
  8. What are Constraints in SQL?
  9. What is a query in SQL?
  10. Difference between Candidate and Alternate Key in SQL?
  11. What are Types of SQL statements?
  12. What is the Primary key In SQL?
  13.  What do You mean By subquery In SQL?
  14. What is RDBMS?
  15.  What are Various Types of Joins In SQL?
  16. What is Set Operator in SQL?
  17. What are the uses of SQL functions?
  18. What is Use of the NVL function in SQL?
  19. What is Different Type of Keys in SQL?
  20.  What are Triggers in SQL?
  21.  What is Clause In SQL?
  22. What is the function of Limit Keyword In SQL?
  23.  What are Types of Database in SQL?
  24. List some DDL commands in SQL
  25. What is the difference between Delete and Truncate in SQL?
  26.  What is Data integrity in SQL?
  27. What is SQL Buffer?
  28.  What is PL/SQL?
  29. What is the difference between PL/SQL and SQL?
  30.  Write a query To find a second highest element of a Column?
  31.  What is normalization in SQL?
  32. What is the user-defined function in SQL?
  33. List Different types of triggers in SQL
  34.  What is the character Manipulation Function?
  35.  What is de-normalisation in SQL
  36.  What are different DDL commands in SQL?
  37.  What are different TCL commands in SQL?
  38.  What is Index in SQL?
  39. Explain Acid Property in SQL?
  40.  What is the difference between where and having a clause?


SQL Interview Question for Experienced Professionals

  1.  What is Collation in SQL?
  2.  What is schema in SQL?
  3.  What are the different types of tables in SQL?
  4.  What is the Unique Key in the SQL table?
  5. Explain Window authentication mode in SQL server?
  6. What are the Types of replications in SQL servers?
  7. Write a command to Create a Table in SQL?
  8.  What is the DBCC command in the database?
  9. What is the use of the BBCC command?
  10. How to use IF statement inside a SELECT statement in SQL?
  11.  What is the difference between commit and Savepoint?
  12. What is the difference between Union and UNION ALL?
  13. what is the Scaler function in SQL?
  14. What is View in SQL?
  15. What is the difference between clustered and Non-Clustered indexes?
  16. What `is the use of stuff() Function in SQL?
  17. What are relationships in SQL?
  18.  What is Data Warehouse?
  19. What is Online Transaction Processing (OLTP) in SQL?
  20. What is the difference between SQL, Oracle, and SQL servers?
  21. What is the Cartesian Product of two tables in SQL?
  22. What is the condition for two tables to be UNION compatible in SQL?
  23.  What are Data Models in the database?
  24. What is the DisAdvantage of DBMS?
  25. What is the use of COALESCE function in SQL?


Download SQL Interview question PDF

Get PDF of SQL interview questions. Just Scroll down this SQL Interview Questions Article and download SQL interview Questions PDF. You can download SQL testing interview questions.

SQL interview questions


SQL Interview Questions Queries

Here is the list of  Tricky SQL queries for Interviews SQL Interview Questions  based on queries are as follows:

  1. Write SQL query to Combine Two Tables 
  2. Write SQL query to find second Highest Salary
  3. Write SQL query to find Nth Highest Salary
  4. Find duplicate e-mails in the SQL database
  5.  Swap Salaries of two Employees
  6.  Count number of Entries in a field
  7. Arrange Entries in Ascending Order
  8. Arrange entries in Descending Order
  9. Sort Name in Alphabetical Order in SQL
  10. Sum of Marks of all students in Student Database
  11. Write SQL query to find Average of Marks
  12.  SQL query to find Minimum entry of a Column
  13. SQL query to show only ODD rows
  14. SQL query to show only even Rows
  15.  SQL Query to show current data
  16.  SQL query to show current time
  17. SQL Query to find Employees with the same salary
  18.  Write SQL query to show the last record from table
  19.  Write a SQL query to find Nth Minimum Salary
  20.  Write a SQL query to show the name of employees whose D.O.B is between 2002 to 2007
  21. Write SQL query to find duplicate rows in Table
  22.  Write SQL query to Join two Table
  23. Write a SQL query to show employees whose names start with 'A'.
  24.  Write a SQL query to Find Month from Date
  25. Write a SQL query to Find Day from Date
  26. Write a SQL query to Find Year from Date
  27. Count Distinct element of a field in SQL
  28.  Write SQL query to Update Salary of an Employee?
  29.  Write a SQL query to merge duplicate rows?
  30. Write SQL to query to find the version of SQL server?
  31. SQL query to Find Foreign Key
  32. SQL query to set foreign Key
  33. SQL query to set  Primary key
  34. SQL query to fins Primary key
  35. SQL query to change the primary key

 Frequently Asked SQL interview Question


1. What are the Rules to write SQL commands and statements?

Rules to write SQL commands are a follows:
  • SQL statements are Case insensitive.
  • The comma is used to separate arguments/parameters.
  • SQL queries can be executed on more than one table at a time
  • A semicolon is required at the end of Statements
  • A statement can be written in multiple lines.

2. What is the Advantage of  DBMS?

    • Reduces data Redundancy which means eradicate data duplicacy
    • Sharing of Data is very Easy
    • High speed
    • Protection of information
    • Reduces programming costs
    • You can easily backup data

3. What is the disadvantage of DBMS?

  • It is costly
  • Sometimes database failure can pause your work
  • It requires a high-speed processor and high memory size.
  • They are very complex
  • Frequently updates and replacements cost very high.

Download SQL Interview Question PDF

Here is The pdf of all tricky and advanced SQL interview questions. Download it now.






There are questions based on tricky SQL queries for interviews in amazon, Flipkart, Apple, and Google. These are the important question for SQL interviews asked frequently in every tech interview. Either You are applying for data analyst or data scientist these questions will be beneficial in cracking your interview.



You May Like -:

1. Java Interview Question and Answers
2. ShortCut Keys in VS Code
3. SQL Tutorials