Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: DDL/DML and rollback
In article <cu4l4d$pq0$1_at_nemesis.news.tpi.pl>, vertigo says...
>
>
>
>>
>> Think of it: when your database crashes during drop table, and the DDL
>> hasn't been yet automatically committed, shouldn't Oracle be capable
>> to rollback the operation?
>>
>
>Ok, but what about truncate:
>I found that: 'truncate is a DDL statement and generates no rollback
>information'. What happen when database crashes during truncate table ?
>
there is no undo generated for the segment being truncated (no need, the data is left untouched on disk)
however, the dictionary updates that take place generate UNDO - so that in the event of a crash in the middle of the truncate (before it completes, before it commits) -- the database will be able to "undo" the partial truncate.
>Thanx
>Michal
>
-- Thomas Kyte Oracle Public Sector http://asktom.oracle.com/ opinions are my own and may not reflect those of Oracle CorporationReceived on Sun Feb 06 2005 - 02:46:13 CST