Lock and Connection Management

Technical Article

SQLPing.vbs

  • Script

Troubleshooting intermitten connectivity issues can be difficult. One approach is to repeatedly test connecting to SQL Server outside of an existing application in order to verify if a server-wide intermitten issue is occurring. This script is used to test remote connectivity to a SQL Server. The script loops in one minute intervals (adjust as needed). […]

You rated this post out of 5. Change rating

2006-09-04 (first published: )

1,419 reads

Technical Article

sp_what

  • Script

This is a replacement for SP_who and modification of sp_who2. It will always list only active, nonsystem processes, and will list the number of seconds a transaction has been running for. Some transactions do not report a last batch time, so I forced a large value to display so you can see any issue with […]

5 (1)

You rated this post out of 5. Change rating

2006-10-02 (first published: )

2,249 reads

Technical Article

To Identify blocks if using Solomon IV

  • Script

Our business accounting software is Microsoft Business Solutions Solomon IV.which is now being called Dynamics Solomon. You will see specific refernces to this software in this code. I originally developed this to gain faster view of issues we were having with Solomon. This procedure analyzes system tables and looks for blocks. This isfaster than using […]

You rated this post out of 5. Change rating

2005-11-03 (first published: )

398 reads

Technical Article

Save results DBCC SQLPERF(UMSSTATS) in a table

  • Script

Examining the output of DBCC SQLPERF(UMSSTATS) helps in determining a CPU bottleneck. The output of the command is not handy for further investigation (from a table).This procedure performs a transformation of the results, so it is easy to query and store in a database.

You rated this post out of 5. Change rating

2005-11-04 (first published: )

1,942 reads

Technical Article

Blocked Process script for deadlock correction

  • Script

This script was created to find an application problem that was causing SQL Server blocked processes. The BlockedProcess table is created to log both the blocker and blocked processes. The sp_BlockedProcess stored procedure is created to handle the situation by: inserting all processes affected by the blocking, notifying the blocking application user, emailing the admins […]

5 (2)

You rated this post out of 5. Change rating

2005-12-01 (first published: )

4,159 reads

Technical Article

Extract data from sp_who for specific database

  • Script

sp_who (and sp_who2) work great for a quick view of what's going on in the system, and can be filtered by user, but there's no way to filter by database. This quick stored procedure provides data on which users are accessing a specific database.

You rated this post out of 5. Change rating

2004-09-13

860 reads

Technical Article

Kill all SPIDs with a certain user ID

  • Script

This script is used to disconnect all connections by a particular individual to a server. I use it when I have to disconnect somebody and they have too many processes to do it by hand. Normally, you can just connect the offending process, but if there are multiple processes that are causing a problem , […]

You rated this post out of 5. Change rating

2004-03-08

2,408 reads

Technical Article

blocked  and blocker  spid and details

  • Script

2 steps:step 1 => create   a table in master database called BlockCheckstep 2 =>  create the stored procedure in master  called  BLOCK_CHECK @database_name varchar(20)What SP  does:-    it gets the  spid that is blocked  + info about it (like what it does  at the moment  it is blocked)-    it gets the spid  that  acts as a […]

4 (1)

You rated this post out of 5. Change rating

2003-06-05

717 reads

Technical Article

Script to kill the top blocker and report what it was doing.

  • Script

This script identifies the blocking locks at the top of the blocking chain and kills them. Specifically, it reports what the top blocking spids are doing, kills them, waits three seconds and then reports on current blocking status.  If you have a situation where single connections are causing a huge blocking chain and you want […]

4.75 (4)

You rated this post out of 5. Change rating

2003-05-12

4,165 reads

Blogs

Announcements from the Microsoft Fabric Community Conference

By

(Shameless plug: The price of my book “Deciphering Data Architectures: Choosing Between a Modern...

The Basics of TRY CATCH Blocks–#SQLNewBlogger

By

I was working with a customer and discussing how to do error handling. This...

Working with ALS – Insights from the Ability Summit

By

The 14th annual Ability Summit is a global event that I attended a few...

Read the latest Blogs

Forums

Best Digital Marketing Agency in Mohali

By socialtheka

In today's fast-paced world of digital marketing, businesses need to choose the right agency...

The Journey to Change

By Steve Jones - SSC Editor

Comments posted to this topic are about the item The Journey to Change

Check Azure SQL DB Space Used

By Cláudio Silva

Comments posted to this topic are about the item Check Azure SQL DB Space...

Visit the forum

Question of the Day

The Cloned Database Size

I have a small test sandbox database on an instance with default master, model, msdb, and tempdb settings. The database has these files:database file propertiesI now run this command:

DBCC CLONEDATABASE(sandbox, sandbox_clone);
GO
When I examine the database file properties, what do they show?

See possible answers