Category: SQL Server

Scalability and Performance Enhancements in SQL Server 2012

The SQL Server product group has made significant modifications to the existing SQL Engine to improve scalability and Performance associated with the SQL Server Database Engine. Some of the main enhancements that allow organizations to improve their SQL Server workloads include the following: Columnstore Indexes More and more organizations have a requirement to deliver Breakthrough

Get Object Names Based on Parameter

If we now the parameter name and want to know the Objects using that parameter then in that case we can use the below stored procedure to retrive the Object Names /*********************************************************************** * Author : V.U.M.Sastry Sagi * Date   : 11/16/2011 * Purpose: Returns all Objects including SPs and Functions based on            given parameter

SP_Depends Wont Work

I had observed that sp_depends wont work properly in many scenarios. So i had wrote this code to fetch the dependent objects on a table. /*********************************************************************** * Author : V.U.M.Sastry Sagi * Date   : 11/11/2011 * Purpose: Returns all Objects Dependent on a table ***********************************************************************/ CREATE PROCEDURE spDepends     (       @TableName VARCHAR(100)     )

Finding Possible Bad Indexes in SQL Server

CREATE PROCEDURE FindPossibleBadIndex AS BEGIN -- Possible bad Indexes (writes > reads) DECLARE @dbid INT SELECT @dbid = DB_ID() SELECT 'Table Name' = OBJECT_NAME(s.object_id), 'Index Name' =, i.index_id, 'Total #of Writes' = user_updates, 'Total #of Reads' = user_seeks + user_scans + user_lookups, 'Difference' = user_updates - ( user_seeks + user_scans + user_lookups ) FROM