Link to home
Start Free TrialLog in
Avatar of patriotpacer
patriotpacer

asked on

Script to Rebuild All Indexes

Does anyone have a script that will rebuild all indexes and work in SQL Server 2008 and higher?
ASKER CERTIFIED SOLUTION
Avatar of Éric Moreau
Éric Moreau
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
for on-going maintenance you may want to check ou this:

SQL Server Backup, Integrity Check, and Index and Statistics Maintenance
The SQL Server Maintenance Solution comprises scripts for running backups, integrity checks, and index and statistics maintenance on all editions of Microsoft SQL Server 2005, SQL Server 2008, SQL Server 2008 R2, and SQL Server 2012. The solution is based on stored procedures, the sqlcmd utility, and SQL Server Agent jobs. I designed the solution for the most mission-critical environments, and it is used in many organizations around the world. Numerous SQL Server community experts recommend the SQL Server Maintenance Solution, which has been a Gold and Silver winner in the 2012, 2011, and 2010 SQL Server Magazine Awards. The SQL Server Maintenance Solution is free.
Ola Hallengren
http://ola.hallengren.com/
recommended video:

also refer to
https://www.experts-exchange.com/questions/28163719/Best-time-to-rebuild-indexes-on-the-database.html?anchorAnswerId=39265474#a39265474
Avatar of patriotpacer
patriotpacer

ASKER

Thanks, PortletPaul.

I appreciate the extra assistance.