During Extract/Transform/Load (ETL) projects we do a lot of data loading, deleting and reloading. I have come up...
By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
with this simple solution to better manage and organize the table space and performance during ETL operations. Our table size grew considerably though it has much less data. So any full table scan operation was taking a long time. After we used this method, we reduced the table size, released unused table space and gained lot of time during full table scan operations on the table.
I looked into Oracle documentation on how to reoganize a table and they say to use EXPORT or IMPORT, or it can be done by copying data into a temporary table, using TRUNCATE on the table, and then moving data back to the original table. We were planning to do something like that until I came up with this idea. We use this method to reorganize about 100 tables spanning several GBs of storage space. It was tested using Oralce 18.104.22.168.
We load data into a table by the direct path method:
INSERT /*+ APPEND */
ALTER TABLE <table_name> MOVE;
For More Information
- Feedback: E-mail the editor with your thoughts about this tip.
- More tips: Hundreds of free Oracle tips and scripts.
- Tip contest: Have an Oracle tip to offer your fellow DBAs and developers? The best tips submitted will receive a cool prize -- submit your tip today!
- Ask the Experts: Our SQL, database design, Oracle, SQL Server, DB2, metadata, and data warehousing gurus are waiting to answer your toughest questions.
- Forums: Ask your technical Oracle questions--or help out your peers by answering them--in our active forums.
- Best Web Links: Oracle tips, tutorials, and scripts from around the Web.