p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   Oracle (http://p2p.wrox.com/forumdisplay.php?f=105)
-   -   (oracle 8i)Alter Table <table> coalesce partition (http://p2p.wrox.com/showthread.php?t=19758)

combo October 12th, 2004 05:07 PM

(oracle 8i)Alter Table <table> coalesce partition
 
Hi all,
    Need assistance in solving a problem. I have a possibly large fragemented table. I tried to run a coalese command ALTER TABLE EMPTY_COPY COALESCE PARTITION
got an error: 'ora -14501 - object is not partitioned'

NOt sure how to proceed, I am working in oracle 8i environment.

Should I do :

ALTER TABLESPACE MY_DATA COALESCE
ALTER INDEX EMPTY_COPY_PK COALESCE
ALTER INDEX EMPTY_COPY_PK REBUILD
ALTER TABLE MY_DATA.EMPTY_COPY MOVE TABLESPACE NEW_DATA

Not sure if the syntax is correct or which to use, are there any redundancies in the commands above.

Thanks kindly for any input you may provide.




Justin Cave October 12th, 2004 10:53 PM

Are you doing this in a production database? If so, what sort of downtime are you allowed?

Unless you have partitioned tables, you wouldn't want to use COALESCE PARTITION. Coalescing a tablespae combines contiguous free extents in a tablespace into one large extent.

What sort of tablespaces do you have? Locally managed or dictionary managed?

Justin
Distributed Database Consulting, Inc.
http://www.ddbcinc.com/askDDBC

combo October 12th, 2004 11:12 PM

Hey Justin,
    Yes, this will be done on a production database. I will the have weekend to handle this. I believe it is a locally managed. The free space coalesced was at 88%. My real problem is an ora 1653 'UNABLE TO EXTEND TABLE' error where I could not insert into a table. The PCT_INCREASE was at 25 and the next_extext was at 160mb. Way too large. There still looks to be l plenty of space available for an another extent but it is not being allocated.

Justin Cave October 13th, 2004 09:35 AM

Locally managed tablespaces (LMT) do not get fragmented and objects in a LMT tablespacs do not have a PCT_INCREASE setting. It sounds like you are describing a dictionary managed tablespace (DMT).

If you have downtime over the weekend, I would seriously and strongly consider migrating to LMT's.

Justin
Distributed Database Consulting, Inc.
http://www.ddbcinc.com/askDDBC


All times are GMT -4. The time now is 06:51 AM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.