SQL SERVER – How to Convert CollationID to Collation Name?

One of my blog readers sent email to me asking if there is a way to convert CollationID to Collation name. I replied asking more details about the requirement. Here is her reply.

Pinal,
I am in a trouble right now. Due to a hardware crash, I lost many of database files. Unfortunately, I don’t have backups, but I was able to retrieve MDF files. I was trying to follow your blog

Read More

SQL SERVER – How to Identify Columns Used In A View?

The views are very tricky. Sometimes they help performance and sometimes they negatively impact performance. Recently, during Comprehensive Database Performance Health Check, I realized that one of the view was the real performance killer. The challenge was to identify column used in a view. We decided to open the view and list all the columns but that was very cumbersome tasks. Finally, we decided to write a script which can help identify columns used in a view. 

Read More