Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Rebuilding Indexes

Status
Not open for further replies.

jocasio

IS-IT--Management
Oct 11, 2002
88
US
Hey all:

I was wndering if there was a way to automatically rebuild indexes in a DB. I was told that I should rebuild them approximately every 6 months. I just rebuilt one on a table (by creating a ddl, dropping the index and then running the ddl)and my queries are running much faster now. I've also started updating statistics on this db every week

Thanks for your help

jocasio
 
jocasio,

My first suggestion: Since you are aware that these type of features keep getting improved with each version and platform, you MUST specify which platform and version you are discussing about. Just a suggestion to help serve you better.

As for automatically rebuilding the index, there is no option in indexes for running automatically. You can write a script to drop and create the indexes and put the script in to the job scheduler (Crontab / NT scheduler / Autosys) for automatic running at certain intervals.

You can also consider the " reorg rebuild " command .
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top