The CPU is responsible for not only SQL Server operations but also all the OS tasks related to the CPU. Let us learn about measuring CPU Pressure.
SQL SERVER – Get Last Running Query Based on SPID
We often need to find the last running query or based on SPID need to know which query was executed. SPID is returns sessions ID of the current user process. The acronym SPID comes from the name of its earlier version, Server Process ID. To know which sessions are running…
Read MoreSQL SERVER – Performance Counters from System Views – By Kevin Mckenna
I just love social media and all the new concepts of Web 2.0. There are bloggers who are overwhelmed by the new concepts of technology and are not able to keep pace with it. But I like taking such challenges. Twitter has acquired tremendous popularity nowadays and just like everybody…
Read MoreSQL SERVER – List All Objects Created on All Filegroups in Database
When I pen down any article I always keep my readers in my mind. With every topic of SQL server I cover, I try to bring readers closer to this technology. So, whenever I receive follow up questions from my readers I am exhilarated! Sometime back I had covered a…
Read MoreSQL SERVER – List All the Tables for All Databases Using System Tables
Today we will go over very simple script which will list all the tables for all the database. sp_msforeachdb 'select "?" AS db, * from [?].sys.tables' Update: Based on comments received below I have updated this article. Thank you to all the readers. This is good example where something small like this have good participation from…
Read MoreSQL SERVER – Interesting Observation of DMV of Active Transactions and DMV of Current Transactions
This post is about a riveting observation I made a few days back. While playing with transactions I came across two DMVs that are associated with Transactions. 1) sys.dm_tran_active_transactions – Returns information about transactions for the instance of SQL Server. 2) sys.dm_tran_current_transaction – Returns a single row that displays the…
Read MoreSQL SERVER – Reseed Identity of Table – Table Missing Identity Values – Gap in Identity Column
Some time ago I was helping one of my Junior Developers who presented me with an interesting situation. He had a table with Identity Column. Because of some reasons he was compelled to delete few rows from the table. On inserting new rows in the table he noticed that the…
Read More