Databases Reference
In-Depth Information
14. Create a temporary table, which is an empty copy of BIG_ROWS :
CREATE.5* FROM HR.BIG_ROWS WHERE 1=0;
15. Copy the migrated rows to the temporary table:
INSERT INTO TEMP_BIG_ROWS
SELECT B.* FROM HR.BIG_ROWS B, HR.CHAINED_ROWS T
WHERE T.OWNER_NAME = ‹HR› AND T.TABLE_NAME = ‹BIG_ROWS›
AND T.HEAD_ROWID = B.ROWID;
16. Delete the migrated rows from the BIG_ROWS table:
DELETE FROM HR.BIG_ROWS B WHERE EXISTS (
SELECT T.ROWID FROM HR.CHAINED_ROWS T
WHERE T.OWNER_NAME = ‹HR› AND T.TABLE_NAME = ‹BIG_ROWS›
AND T.HEAD_ROWID = B.ROWID);
17. Copy the migrated rows from the temporary table back to the BIG_ROWS table:
INSERT INTO HR.BIG_ROWS SELECT * FROM HR.TEMP_BIG_ROWS;
18. Analyze the table to refresh the statistics:
ANALYZE TABLE HR.BIG_ROWS COMPUTE STATISTICS;
19. Verify if there are migrated rows:
SELECT CHAIN_CNT FROM ALL_TABLES WHERE OWNER = 'HR'
AND TABLE_NAME = ‹BIG_ROWS›;
 
Search WWH ::




Custom Search