It is not possible to use CASE Expression in Default Values when you add a new column. I hope this answers the question. However, there is a workaround.
Queries Using Specific Index – SQL in Sixty Seconds #180
The challenge I face is that often DBAs ask me to prove that indexes are really not used by queries. Let us learn about Queries Using Specific Index.
SQL SERVER – Find Instance Name for Availability Group Listener
How to Find Instance Name for Availability Group Listener? I was recently asked this by DBA at Comprehensive Database Performance Health Check.
SQL SERVER – Finding Queries Using Particular Index
One of the most popular questions I received during my Comprehensive Database Performance Health Check is Finding Queries Using Particular Index.
SQL SERVER – Applying Query Hints to Views
I totally agree that it is not possible to apply query hints to views inside the view. It will give you an error. However, there is a workaround.Â
SQL SERVER – Altering Column – From NULL to NOT NULL
Let us see a very simple script today. It is about Altering Column – From NULL to NOT NULL. Comprehensive Database Performance Health Check
SQL SERVER – Quick Look at Suspected Pages
Well, let us take a Quick Look at Suspected Pages which contains details about corrupted pages. They have been running DBCC commands regularly.