Skip to Main Content

SQL & PL/SQL

best way to remove millions of rows

user8983130Jul 11 2020 — edited Jul 24 2020

Dear All,

I have a table with around 60 millions of rows, It contains data from 2008. Now, I have decided to remove data upto 2018,31st of December.There is a column with date which i can use to delete rows. For example,delete from table where column_to_be_del < sysdate -365; The problem is if i want to delete all data at a time it will generate huge number of undo/redo files which the system can't handle. Or, I can try to delete small portion of data in every weekend so that less undo/redo generates. I can figure out these 2 options.

Can you suggest if there are better ways to do the task?? For exmaple, a procedure to delete rows which will commit every 100000 of rows.

Regards,

Comments
Post Details
Added on Jul 11 2020
11 comments
412 views