Performance degrade while deleting 1 million row [message #439026] |
Wed, 13 January 2010 12:08 |
manish_edu
Messages: 2 Registered: January 2010
|
Junior Member |
|
|
Hi ,
I have to delete 1 million row from my table as the data was incorrectly inserted..
It is production system and deleting 1 million row will make the database die and user will have to stuck their operation for long..
Please guide me the best suitable way to delete these rows..
|
|
|
|
|
|
|
|
|
Re: Performance degrade while deleting 1 million row [message #439075 is a reply to message #439064] |
Thu, 14 January 2010 01:38 |
|
Michel Cadot
Messages: 68718 Registered: March 2007 Location: Saint-Maur, France, https...
|
Senior Member Account Moderator |
|
|
1/ NOLOGGING works only on direct path operation which is not the case of a DELETE. (In addition, it implies a backup after the operation.)
2/ Autocommit SQL*Plus feature auto commits after x DML statements not after x modified/deleted rows, so it does nothing in a single DELETE
3/ Committing inside a loop does not avoid ORA-1555 it INCREASES the likelyhood to get it.
Time to review your basics.
Regards
Michel
[Updated on: Thu, 14 January 2010 01:39] Report message to a moderator
|
|
|
|
|
Re: Performance degrade while deleting 1 million row [message #439092 is a reply to message #439089] |
Thu, 14 January 2010 03:49 |
|
Michel Cadot
Messages: 68718 Registered: March 2007 Location: Saint-Maur, France, https...
|
Senior Member Account Moderator |
|
|
To know if alternative way might be the more efficient way, we will have to wait for OP to answer BlakcSwan's question. And the one you pointed to might not be the most efficient one.
In addition, you can't do it in while others are working, and for the moment OP wants to do it without stopping the application (as his sentence "user will have to stuck their operation for long" seems to imply).
Regards
Michel
|
|
|