SQL Server: Quick Space & File Layout Analysis With PowerShell and PowerBI

Long time ago, I created a little chunk of TSQL to get a glimpse of my space and file layout information at the Database/File/Filegroup level. It is a basic routine that spins through all the databases of an instance to collect space usage data. Over the years, I have used it a lot and it … Continue reading SQL Server: Quick Space & File Layout Analysis With PowerShell and PowerBI

Oracle: Find The Total Size Of All Of Your CLOB & BLOB Columns In All Tables

Today I received a request from an application owner who wanted to know the size of all the CLOB and BLOB columns in all the non-system tables so that they have a good idea of the size involved for a migration. Tables with BLOB/CLOB columns The SQL to find the tables with the BLOB/CLOB columns … Continue reading Oracle: Find The Total Size Of All Of Your CLOB & BLOB Columns In All Tables

SQL Server: A More Flexible xp_ReadErrorLog That Reads All Error Logs Including Archives

I am sure that all of you are already familiar with the extended stored procedure xp_ReadErrorLog and its less flexible and published equivalent sp_ReadErrorLog (which takes less parameters) for reading the SQL Server Error Log. xp_ReadErrorLog - To read current error log: The extended stored procedure xp_ReadErrorLog is very useful. It helps with reading the … Continue reading SQL Server: A More Flexible xp_ReadErrorLog That Reads All Error Logs Including Archives

SQL Server: Detach/Attach Gotchas!

Please checkout my post on "Moving Datafiles" which is very related to this method but is preferred more. One would think that detaching and attaching databases is one of the simplest things to do. It is. However, there are so many things that can break by that simple operation by itself and nothing more. Recently, … Continue reading SQL Server: Detach/Attach Gotchas!

SQL Server: Dynamically Calculate Delta Values For Numeric And Date Columns From DMV’s Or Any Table

DMV's are very useful. In fact, they are like glass windows that lets you look at a running engine. There are lots of them and they give us lots of numbers but Most are cumulative in nature!  i.e., the numbers keep on increasing and never decrease. A variation of above like space usage where the … Continue reading SQL Server: Dynamically Calculate Delta Values For Numeric And Date Columns From DMV’s Or Any Table