There are times where you need to massively rebuild indexes on some really large databases, after indicated by the relevant analysis of course. However, rebuilding indexes, requires also the adequate amount of free disk space that will be used during the rebuild operation (mainly for the sorting process). Usually the required…
How to rebuild all the indexes of a database in SQL Server
In one of my previous posts, I talked about Index Fragmentation in SQL Server in terms of how to track it and how to resolve it. In this post, we are going to see how to rebuild all the indexes of a database in SQL Server. The techniques explained in…
Index Fragmentation in SQL Server (Reorganizing/Rebuilding Indexes)
1. Overview————SQL Server automatically maintains indexes whenever insert, delete, or update operations are performed on the underlying data. Though, in the cases where the underlying data contain very large volumes of information, the information in the indexes become scattered over time. This is known as Index Fragmentation. Index fragmentation can…
Getting table index information in SQL Server
At some time today, I had to compare the indices of various database tables.To this end, I needed a fast way of getting index information for specific tables. In SQL Server, there is a system stored procedure (hosted in the master database) called sp_helpindex. The syntax for using it is…