External Article

Purging Data from a Large Table in SQL Server

Purging data from a table is a common database maintenance task to prevent it from growing too large or to stay in compliance with data retention. When dealing with small amounts of data, this can be accomplished by a simple delete with no issues; however, with larger tables, this task can be problematic. Deleting records requires a lock that can block other processes from writing or even reading the data (depending on your isolation level). In this article I will share a technique I have used to work with some very large tables.

SQLServerCentral Editorial

Greener Grass

Before I start the whining (whinging if you prefer), let me just say I have the greatest job in the world. I'm exceedingly lucky to have it. I'm grateful as can be. And someone else (looking at you Tim) can get it when they pry it from my dead cold fingers. With that out of […]

Blogs

Comparing Microsoft Fabric Alternatives in AWS, GCP, and OCI in 2025

By

Microsoft's unified analytics platform, Fabric, simplifies integration across various tools in Azure by offering...

Techno Security East: Quantum Computing Slides

By

I always try and ensure that I post my slides to my talks here...

A Basic Update Trigger: #SQLNewBlogger

By

I had someone ask me about using triggers to detect changes in their tables....

Read the latest Blogs

Forums

SSIS raw file conversion

By bokswager

Hi, Does anyone know how to handle a raw data file where some rows...

Force Strict Encryption - SQL Agent fails

By gustaw1234

Hi, On my SQL 2022 (16.0.4195.2) test environment, I tried to enable Force Strict...

Error converting data type varchar to float

By water490

Hi everyone I have a bunch of CSV files that I need to import...

Visit the forum

Question of the Day

How Many Nested Triggers?

I have DDL trigger code that I'm working on in SQL Server 2022, but I am concerned that we might end up with multiple triggers firing and the response to the user is delayed. If I want to check how many triggers have fired, or are nested, how can I do this in my code?

See possible answers