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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

reindex a table

Status
Not open for further replies.

Glowworm27

Programmer
May 30, 2003
587
US
i have a table that has millions of rows. just recently the query we run to look for errors is timing out, i need to run this query before sending the payroll data. Is there as way to reindex this table in hopes to speed this up, so the query can complete? I only have an hour so redesigning the tables now wont work.....


George Oakes
CEO & President
COPS Software, Inc.

Programmer & Developer
.Net, WSS 3.0, SQL DBA
Check out this awsome .Net Resource!
 
George,

If you simply want to do a fast re-index, then here is your code:
Code:
SQL> alter index s_emp_id_pk rebuild parallel;

Index altered.
Let us know if this takes care of business for you.

[santa]Mufasa
(aka Dave of Sandy, Utah, USA)
[I provide low-cost, remote Database Administration services: www.dasages.com]
“Beware of those that seek to protect you from harm or risk. The cost will be your freedoms and your liberty.”
 
So, you've not told us the structure of the table, you've not told us what indexes you have on it, and you've not told us what query you're running on it. And you want us to tell you - within an hour - if it's possible to speed it up?

I'm gonna go with "Yes", because I'm a positive kinda guy, but it could be "No". I hope you find this helpful.



-- Chris Hunt
Webmaster & Tragedian
Extra Connections Ltd
 
If you give us the select, we can probably suggest ways to speed up the query. Have you paid for the partition option?

Bill
Lead Application Developer
New York State, USA
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top