From: "Jonathan Lewis" <jonathan@jlcomp.demon.co.uk>
Newsgroups: comp.databases.oracle.server
Subject: Re: On Indexes and Commits
Date: Wed, 8 Aug 2001 14:48:12 +0100
Message-ID: <997278489.28573.0.nnrp-13.9e984b29@news.demon.co.uk>
References: <lvd2ntcneshf4nqvqf3vif6as71u5o5k05@4ax.com>
NNTP-Posting-Host: jlcomp.demon.co.uk
X-NNTP-Posting-Host: jlcomp.demon.co.uk:158.152.75.41
X-Trace: news.demon.co.uk 997278489 nnrp-13:28573 NO-IDENT jlcomp.demon.co.uk:158.152.75.41
X-Complaints-To: abuse@demon.net
X-Newsreader: Microsoft Outlook Express 4.72.3110.5
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3
Lines: 39



General principle. when you insert a row into
a table, you insert the index entries at the
same time. There are minor variations on a
theme, but as each INSERT statement
completes, the table and its indexes are
self-consistent.

Rolling back is very expensive - start
looking into TEMPORARY TABLES
with 'on commit delete rows'.

--
Jonathan Lewis

Seminars on getting the best out of Oracle
Last few places available for Sept 10th/11th
See http://www.jlcomp.demon.co.uk/seminar.html




Kirt Thomas wrote in message ...
>We're sitting here puzzling over this :)
>
>Our developers use a table to store data during the execution of a
>report, they may end up inserting several to tens of thousands of
>records into this table to be reported on (of course this is a bad,
>but that's neither here nor there right now).  The way the dev's are
>handling the records in this 'temp' table is to do no commit, and
>issue a rollback after the report is done - effectively cancelling the
>inserts.  This allows multiple reports to run at the same time as each
>report only see's it's own sessions data.
>
>My assertion is that doing things this effectively negates any indexes
>on the table.  I don't see how they could be used w/out commiting the
>data.  Is this true?  Thanks.



