T-SQL query to find the list of objects referring Linked Servers
Category: Queries
T-SQL script to find hierarchy of tables – Row-wise result
As I promised in my previous post T-SQL script to find hierarchy of tables – Columnar result, here is another version of the query to get the hierarchy of tables in the form of rows. ; WITH cte_Hierarchy_Of_Tables AS ( SELECT A.[name] AS [Parent] , A.[object_id] AS [Parent_Object_ID] , A.[name] AS [Child] , A.[object_id] AS … Continue reading T-SQL script to find hierarchy of tables – Row-wise result
T-SQL script to find hierarchy of tables – Columnar result
One of my LinkedIn connection reached out to me for help, to find the hierarchy of all the tables in a database. He was in dire need of some help, since there are around 250 tables in his database, and he need to write delete script to delete data requested by his team. As we … Continue reading T-SQL script to find hierarchy of tables – Columnar result
Estimating the storage savings by removing columns with NULL value across the table or marking them as SPARSE
In the previous article Find columns with NULL values across the table we discussed that storage space can be saved by removing columns with NULL value across the table or marking them as SPARSE. We also learnt about the query to find all such columns across the tables of a database. In this article we'll … Continue reading Estimating the storage savings by removing columns with NULL value across the table or marking them as SPARSE
Find columns with NULL values across the table
Recently, I was working on one of the performance tuning assignment with an esteemed client. The size of their databases were growing tremendously. Growth in the database size is directly proportionate to disk space requirement. More the database size will be, more disk space will be required. When we talk about the disk space for … Continue reading Find columns with NULL values across the table