
Copyright © 2001, 2015, Oracle and/or its affiliates. All rights reserved.
If the table is monthly, then the data is segmented as follows:
If the table is weekly, then the data is divided as follows:
Every table reuses its partitions, because the intention is that before the end of the cycle, the oldest
partition is purged in preparation for the new cycle. In other words, for a monthly table, on April 30th,
partition 1 should be purged to remove January’s data, which will then be used for May.
Truncate Jobs for Partitioned Tables
In order to make truncating the partitioned tables as seamless as possible, a script is provided that
submits an Oracle Database job to automatically purge the oldest partition, on the last day of the
cycle. These jobs should be submitted as a final step in any migration, logged in as GLOGOWNER.
1. Enter SET SERVEROUTPUT ON to be able to see feedback.
2. Run Exec partit.submit_job(‘WW’);
3. Run Exec partit.submit_job(‘MM’);
4. Run Exec partit.submit_job(‘Q’);
5. Run Exec partit.submit_job(‘D’);
These jobs are set to run at 1 AM on the last day of the cycle by default.
Comentarios a estos manuales