| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> c.d.o.server -> Re: Why would an Insert /*+ append */ be slower than a straight insert?
from the Oracle 9i Performance Tuning Guide and Reference:
" ...........
In direct-path INSERT, data is appended to the end of the table, rather than using existing space currently allocated to the table. As a result, direct-path INSERT can be considerably faster than conventional INSERT.
append_hint::=
................"
and obviously, this result also in generating much less redo blocks from insert.
"Ryan Gaffuri" <rgaffuri_at_cox.net> a écrit dans le message de
news:1efdad5b.0305230310.566022bb_at_posting.google.com...
> "Sybrand Bakker" <postbus_at_sybrandb.demon.nl> wrote in message
news:<vcqja2a2ue9352_at_corp.supernews.com>...
> > "Ryan" <rgaffuri_at_cox.net> wrote in message
> > news:UOaza.52438$823.38070_at_news1.east.cox.net...
> > >
> > > "Sybrand Bakker" <gooiditweg_at_nospam.demon.nl> wrote in message
> > > news:m4cqcvkhg10ubofeq738bko4ns4nunaqj9_at_4ax.com...
> > > > On 22 May 2003 12:45:55 -0700, rgaffuri_at_cox.net (Ryan Gaffuri)
wrote:
> > > >
> > > > >Here is the situation. Im testing a load process and I need to show
> > > > >results between the old method and a newer method to management.
> > > > >
> > > > >Here are the details.
> > > > >I did an
> > > > >
> > > > >Insert /*+ append */ into Master
> > > > >select * from stage;
> > > > >
> > > > >Also did it without append and the regular insert was about 40%
> > > > >faster. Here are the details.
> > > > >
> > > > >Oracle 8.1.7
> > > > >Solaris v5.8
> > > > >Each table in a seperate tablespace
> > > > >Same I/O device for everything
> > > > >Both tablespaces are taken offline to flush the DB_BUFFER_CACHE
> > > > >ALTER SYSTEM FLUSH SHARED_POOL; issued as well.
> > > > >2.5m rows inserted.
> > > > >Master table is truncated between loads
> > > > >There is a primary key with 7 columns that is enabled(yes I know
> > > > >append is faster with disabled, but Im testing all possibilities)
> > > > >Both TABLESPACSE are set to NOLOGGING
> > > > >Both Tables are set to NOLOGGING.
> > > > >Only one session is active on the server. Nothing else is going on
> > > > >
> > > > >any ideas? Id assume at worst Append would be the same speed?
> > > >
> > > >
> > > > The sensible approach would have been to enable event 10046 level 12
> > > > for the affected sessions, so you could investigate *what* it was
> > > > waiting for. Now you are calling for a Niemic-like advice, like
> > > > increase the buffer cache, increase the shared pool etc.
> > >
> > > Im in the learning process. I do not know much of anything about event
> > > tracing. I have posted that before.
> > > Ive started reading metalink documents on statspack.
> > >
> > > do you know any good documents on sqltrace? Any you recommend? How
many
> > > trace events are there?
> > > I dont even know how to tell which trace file this created.
> > >
> > > I was wondering whether there are known conditions where append might
be
> > > slower.
> > >
> > >
> > > >
> > > >
> > > > Sybrand Bakker, Senior Oracle DBA
> > > >
> > > > To reply remove -verwijderdit from my e-mail address
> > >
> > >
> >
> >
> >
> >
begin 666 append_hint.gif
M1TE&.#=A\ $8`/<`````````/P``?P``P ``_P`J```J/P`J?P`JP `J_P!5
M``!5/P!5?P!5P !5_P!_``!_/P!_?P!_P !__P"J``"J/P"J?P"JP "J_P#5
M``#5/P#5?P#5P #5_P#_``#_/P#_?P#_P #__RH``"H`/RH`?RH`P"H`_RHJ
M`"HJ/RHJ?RHJP"HJ_RI5`"I5/RI5?RI5P"I5_RI_`"I_/RI_?RI_P"I__RJJ
M`"JJ/RJJ?RJJP"JJ_RK5`"K5/RK5?RK5P"K5_RK_`"K_/RK_?RK_P"K__U4`
M`%4`/U4`?U4`P%4`_U4J`%4J/U4J?U4JP%4J_U55`%55/U55?U55P%55_U5_
M`%5_/U5_?U5_P%5__U6J`%6J/U6J?U6JP%6J_U75`%75/U75?U75P%75_U7_
M`%7_/U7_?U7_P%7__W\``'\`/W\`?W\`P'\`_W\J`'\J/W\J?W\JP'\J_W]5
M`']5/W]5?W]5P']5_W]_`']_/W]_?W]_P']__W^J`'^J/W^J?W^JP'^J_W_5
M`'_5/W_5?W_5P'_5_W__`'__/W__?W__P'___ZH``*H`/ZH`?ZH`P*H`_ZHJ
M`*HJ/ZHJ?ZHJP*HJ_ZI5`*I5/ZI5?ZI5P*I5_ZI_`*I_/ZI_?ZI_P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