1st thing to remember about databases, is that they require regular maintenance this is no different for SQL Server databases that also require regular maintenance, and this can be a time consuming process. maintenance tasks are easier to create and execute because of the built in Maintenance Plan Wizard MS SQL Server has.
The Maintenance Plan Wizard can be started from SQL Server Management Studio and can be found in the Management section of the tree in SSMS. It creates scheduled jobs which are run by the SQL Server Agent and can perform the following tasks:
- Reorganize index pages
- Rebuild indexes
- Update statistics on the indexes
- Shrink data and log files by removing empty pages
- Backup database and transaction log
- Perform internal consistency checks
- Cleanup tasks
It is worth it to set up maintenance plans to make these everyday tasks much easier.