Before Applying job posting in any websites or recruiting agencies or sending resumes to job recruiters or any other employment website you need to improve your skills on general knowledge, Aptitude, Puzzles, logical reasoning, general english, database, programming as per your job profile. Job recruiters or mostly preferring job candidates who are having more stuff in those categories mentioned above. So improving more skills on your job profile always boost up your career and your performance. Even hiring companies and job recruiters who are looking for many job posting websites actually they are looking and filtering on these activities. In these Sql Server section you need to update more questions to perform well in front of job recruiters and companies. Sql Server Interview questions are most important to score in interview, Update all questions to score well in all rounds in job interview.

Sql Server interview questions and answers

6)
What is the difference between DELETE and TRUNCATE TABLE?

Following are difference between them:

  • DELETE table can have criteria while TRUNCATE cannot
  • TRUNCATE table does not invoke trigger
  • DELETE TABLE syntax logs the deletes thus make the delete operation slow. TRUNCATE table does not log any information but it logs information about deallocation of data page of the table so TRUNCATE table is faster as compared to delete table.
7)
What is Lock escalation?

Lock escalation is the process of converting of low –level locks (like rowlocks, page locks ) into higher –level locks (like table locks). Every lock is a memory structure too many locks would mean , more memory being occupied by locks. To prevent this from happening , SQL Server escalates the many fine –grain locks to fewer coarse- grain locks. Lock escalation threshold was definable in SQL Server 6.5, but from SQL Server 7.0 onwards SQL Server dynamically manages it.

8)
What are the different ways of moving data between databases in SQL Server?

There are lots options available ; you have to choose your option depending upon your requirement Some of the options you have are BACKUP/RESTORE, detaching and attaching databases , replication DTS, BCP , logshipping , INSERT…SELECT, SELECT…INTO, creating INSERT scripts to gencrate data.

9)
What is the difference between a HAVING CLAUSE and a WHERE CLAUSE?

You can use Having Clause with the GROUP BY function in a query and WHERE Clause is applied to each row before, they are part of the GROUP BY function in a query.

10)
What is the difference between UNION and UNION ALL SQL syntax?

UNION SQL syntax is used to select information from two tables. But it selects only diatinct records from both the table, while UNION ALL selects all records from both the tables.