Top SQL Interview Questions with Answers

SQL Logo_www.OracleAppsDNA.com

Click on the question to see the answer

Basic SQL Interview Questions

  1. Can we use a WHERE clause in TRUNCATE statement?
  2. What is the difference between TRUNCATE and DELETE commands
  3. How to find SQL statements which takes more time to run on Database?
  4. What is the different between Analytic and Group function in SQL?
  5. What is the Difference between an Empty String and a NULL value?
  6. What is Referential Integrity?
  7. What is the structure of DUAL table?
  8. How to find record count of a table without using count(*) ?
  9. What is the standard execution sequence of an SQL Statement followed by Oracle Database engine?
  10. Lets say there is a table with 500 rows. Write a query to display rows from 101 to 500.
  11. Query to find records inserted in last 2 hours
  12. To optimize the performance of an SQL statement what should be the order of tables in FROM clause?
  13. To optimize the performance of an SQL statement what should be the order of join conditions in WHERE clause?
  14. When to use EXISTS over IN?
  15. How to select odd number records from a table?
  16. How to display a number in words?

Advanced SQL Interview Questions

  1. Why ROWNUM =(> 1) will not work ?
  2. Why does NULL = NULL Fail in SQL statements?
  3. How to sort a VARCHAR2 field as a Numeric field in SQL?
  4. What is Global Temporary Tables and What is it Purpose?
  5. How would you convert date into Julian date format in Oracle SQL?

Note: New Questions will be added to this list on regular basis