I have created a table : Table1. Inserted 100 thousand rows and deleted. I did the same around 100 times ( inserting and deleting). Will it cause of increasing the database and table size every time? ( I am using Delete instead of Truncate).
Sql-server – Size of the database and table while inserting and deleting in sql server 2005
sql-server-2005
Related Question
- Sql-server – the optimal set of database maintenance tasks for high volume of transactions
- Sql-server – Why does the SQL Server database triple in size after deleting millions of records
- Sql-server – SQL Server Table Move Stalled
- Sql-server – Retrieving data speed tweaks SQL Server 2005
- Sql-server – SQL Server 2005 – Query optimization for fetching large number of rows from table with 750 million rows
- Sql-server – SQL Server 2005 – Generate and Bulk Insert 3 million rows across 2 tables
Best Answer
WHen you use delete the rows actually not deleted but marked as GHOST records, which will finally deleted by dedicated process named GHOST CLEANUP which works relatively slow in background
To force deletion of ghost records run: