Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Insert without redo log

Re: Insert without redo log

From: Howard J. Rogers <howardjr_at_www.com>
Date: Thu, 15 Feb 2001 12:03:51 +1100
Message-ID: <m0Gi6.205$305.67656@inet16.us.oracle.com>

The short answer is "no".

All conventional inserts and updates generate redo. Always

The slightly longer answer is that you can create a table with the "nologging" keyword, and that will prevent redo generations for *some*, highly-specific, forms of DML (in particular, direct loads, direct inserts, parallel inserts and so on. Conventional inserts, however, are not affected by the nologging keyword, and still always generate redo), and particular bits of DDL (create indexes for example)

In 8i, you can do serial inserts with the APPEND keyword, and they do respect the nologging keyword.

Also in 8i, there is now the concept of a global temporary table, and DMLs on them do not generate redo under any circumstances. It is possible you could therefore contemplate loading into a temporary table first,then using an 'insert into blah select * from temptable' to get the data into the main table -that's a direct insert, and would respect a nologging attribute.

I have not, however, ever tried doing a direct insert using a temporary table as the source, so I can't guarantee it would work (and in any case it needs 8i). If you *do* have 8i, and want to try it out, remember that temporary tables are private to a session, and retain data only after a commit if you create them with the 'on commit preserve rows' construct. They are also instantly cleared out when the session ends.

Regards
HJR "Paul Martin" <prmartin_at_bluewin.ch> wrote in message news:96eftq$946$1_at_bw107zhb.bluewin.ch...
> Hello
>
> This question might/does sound a bit strange :
>
> Is there a way to do an Insert/Update without generating any redo log
 data.
> I would like the same reaction
> as a Truncate - no rollback data, no redo log data - but for either an
> Insert or a Transaction.
>
> The reason behind this question is that we have a batch process that
 inserts
> records into a temporary
> table. If possible we don't want these inserts in the redolog data (or
> rollback) because they will not be needed
> even if the system crashes.
>
> Anybody got any ideas ?
>
> Many thanks
>
> Paul
>
>
>
Received on Wed Feb 14 2001 - 19:03:51 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US