Posts

Showing posts from April, 2025

SQL Interview Question - AL1

 Find the duplicate records Delete the duplicate records Find department-wise average, max, min salary Find the emp name from 3rd character Find employee name starts/ ends/ anywhere in the name is R Find the alternate records Difference between Delete, Truncate, and Drop Find the employee name with manager name Find the students details who have not won any prize What are the SQL constraints Write SQL query to find the random employee details Find the second highest/ fifth highest salary of the employee Find the employee details who joined in month of Feb in any year Find the employee details who joined in month of Feb in specific year Find the employee details who joined between specific date to specific date  Find the employee details who joined between specific month to specific month Find the employee details who joined between specific year to specific year Find total employee count who are working in specific department Find total employee count who are working in specif...

SQL Interview Questions - Basics

Write an SQL query to fetch “FIRST_NAME” from Worker table using the alias name as <WORKER_NAME> Write an SQL query to fetch “FIRST_NAME” from Worker table in upper case Write an SQL query to fetch unique values of DEPARTMENT from Worker table Write an SQL query to print the first three characters of FIRST_NAME from Worker table Write an SQL query to print the first three characters of FIRST_NAME from Worker table Write an SQL query to find the position of the alphabet (‘a’) in the first name column ‘Amitabh’ from Worker table Write an SQL query to print the FIRST_NAME from Worker table after removing white spaces from the right side Write an SQL query to print the DEPARTMENT from Worker table after removing white spaces from the left side Write an SQL query that fetches the unique values of DEPARTMENT from Worker table and prints its length Write an SQL query to print the FIRST_NAME from Worker table after replacing ‘a’ with ‘A’ Write an SQL query to print the FIRST_NAME and LAS...