In my recent past, I have helped around 10 customers who have had similar problems while installing SQL Server Cluster on windows. So I thought it would be a nice idea to pen it down as a blog post so that it can help others in future. In this blog post we will discuss about Installation Fails With Error – A Constraint Violation Occurred.
Does Dropping Clustered Index Drop Primary Key on the Same Column? – Interview Question of the Week #083
Question: When we drop clustered index on the column, does it automatically drop primary key on the same column (if created)?
Does Dropping Primary Key Drop Clustered Index on the Same Column? – Interview Question of the Week #082
Question: When we drop primary key on the column, does it automatically drop a clustered index on the same column (if created)?
Answer: This is one of the most popular questions, whenever I ask this to any candidate, they usually give an answer in yes or no. However, if I ask them follow up question to confirm, I have noticed most of the time they change the reply or accept that they really do not know the answer. It is totally fine. As when I was beginning with SQL, I even did not know the answer of it. I learn doing various experiments and doing various interviews.
This is a very interesting question. I really do not know why interviews are fascinated with this question. One of the professional services I offer is to help organizations select an ideal employee for their organization and last week, I was on a conference call with a large MNC who was looking for performance tuning expert for their organization. We interviewed around 50 different employees and offered jobs to 2 experts and 1 has so far accepted it. One of the questions which I see my friends from the interview panel asking again and again was about Primary Key. I noticed that most of the candidate got it correct.
I am an independent database consultant and I focus on SQL Server Performance Tuning. The other day when I was working with my customer on a large project on performance tuning, we noticed a table which had created performance issues and it contains a huge amount of NULL data. In this blog post we will learn about NOT NULL constraint.
There are moments and time when interviewer sometimes gets highly disappointed. Well, I had such a moment a few days ago. Before you look at the answer – please try to answer this SQL SERVER question yourself first. If your answer is incorrect.
Question: Can Primary Key on the any table contain NULL values? Why?
Let us first see script which will return us tablename with schema where clustered index is not a primary key.