Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: SQL*Loader - using direct load path with a table during others performing delete/select
Sybrand Bakker wrote:
> You have just summed up about all the reasons to use staging tables
> Just load the data into staging tables with identical definition of
> the target tables. Clean up your data in the staging phase, making
> sure proper constraints exist on the target tables. Then just insert
> select and there you go.
Or, to add to Sybrand's comments.. if the table definitions are exactly the same Viktor, consider partitioning. It allows you to swap the contents of that staging table with that of the production table.
Some caveats though about partition validation and local/global indexes.. but if you can work with those... It can take less than a second to swap the contents of a staging table with a partition. Irrespective of the size (Oracle does not physically move the data of course).
It also allows you at any time to remove that partition and put it back into a staging table.. for archiving/exporting/special processing etc.
-- BillyReceived on Mon Jun 23 2003 - 10:21:02 CDT