Browse by Tags

SQL Server 2005 TSQL to obtain buffers by object (table, index) in the buffer cache?
01 February 08 05:30 AM | SQL Master | 2 Comments   
As a programmer interacting with SQL Server's cache is not often needed, but when you do need to determine what is going on with the cache, or you simply need to flush the execution plans or data pages to tune a query, you now have the means to do so. Read More...
TSQL to findout blocking and locks on a SQL Server?
07 December 07 12:08 PM | SQL Master | 2 Comments   
Have you ever performed huge operations such as deleting records of a table and processing inserts on that table at the same time? This is a common task that every application will have to perform and you can avoid by fine tuning your queries (mostly Read More...
TSQL to get an index age in a database
06 September 07 06:37 AM | SQL Master | 2 Comments   
SELECT ‘Index Name’ = ind . name , ‘Statistics Date’ = STATS_DATE ( ind . object_id , ind . index_id ) FROM SYS.INDEXES ind WHERE OBJECT_NAME ( ind . object_id ) = ‘Table_Name’ Read More...
Filed under: , , ,
How do I find all the tables and indexes that are partitioned?
17 July 07 02:42 AM | SQL Master | 1 Comments   
If you have a huge number of partitioned tables and indexes then the following query would help you to identify the list of objects that are involved. USE <database_name>; GO SELECT SCHEMA_NAME(o.schema_id) AS schema_name ,OBJECT_NAME(p.object_id) Read More...