Home » RDBMS Server » Server Administration » Rebuild table in same tablespace
Rebuild table in same tablespace [message #15576] Thu, 14 October 2004 12:14 Go to next message
Vin
Messages: 5
Registered: August 2002
Junior Member
Hi all,
I wanted to see if my idea to rebuild a table into the same tablespace would cause a problem.
The situation is that someone had the PCT_INCREASE set to 25 and now te next extent is at 160mb. I would like to rebuild this table to have the same size extents. The table contains 20 millions rows and is 800bmb in size. The table name is EMPTY_COPY and is in the MY_DATA tablespace.

I plan to do this :
ALTER TABLE EMPTY_COPY STORAGE (NEXT 64K PCTINCREASE 0)

ALTER TABLE EMPTY_COPY MOVE TABLESPACE MY_DATA NOLOGGING

Would this work and will it cause problems. I expect downtime, however I am not sure if there is risk of losing or corrupting data.
Also I am not sure if this will improve that data access speed.
Re: Rebuild table in same tablespace [message #15577 is a reply to message #15576] Thu, 14 October 2004 12:31 Go to previous messageGo to next message
Todd Barry
Messages: 4819
Registered: August 2001
Senior Member
For 20M rows, why do you want such small extents? Why aren't you using locally-managed tablespaces with fixed or autoallocated extent sizes?
Re: Rebuild table in same tablespace [message #15579 is a reply to message #15577] Thu, 14 October 2004 13:07 Go to previous messageGo to next message
Vin
Messages: 5
Registered: August 2002
Junior Member
I am supporting a client's database. Not sure why everything is Dictionary managed. Is having too many extents a problem. Then why not just have one?
Re: Rebuild table in same tablespace [message #15580 is a reply to message #15579] Thu, 14 October 2004 15:57 Go to previous message
Todd Barry
Messages: 4819
Registered: August 2001
Senior Member
The number of extents is usually only an issue when you get into the thousands of extents, and sometimes not even then. Locally-managed tablespaces avoid fragmentation by having every extent the same size, or a multiple of a common size.

I was just suggesting that 64K seemed awfully small for a 20M-row table.
Previous Topic: User Tracing Information in new file
Next Topic: Database Name ?
Goto Forum:
  


Current Time: Thu Jan 09 22:51:50 CST 2025