Hi All
I am very new to database stuff.Please ignore if I am wrong.Is there a possiblity to write a script in oracle which deletes the rows from a table based on the age. i.e., I want to delete the rows which are >120 days. I have a table with millions of rows in it and I want to keep only the latest 4 months rows. I have the following table with column names as
ERROR_IND
FEED_ID
QUEUE_ID
FEED_DT_TM
I have written
delete * from table where (sysdate-(feed_dt_tm))>= 120.
But, Is writing a script increases the efficiency than querying the delete statement.
After performing the delete operation, I need to partition the table. I am confused on how to handle it as I am very new to this stuff. Please advise me on this issue.
Thanks In advance
I am very new to database stuff.Please ignore if I am wrong.Is there a possiblity to write a script in oracle which deletes the rows from a table based on the age. i.e., I want to delete the rows which are >120 days. I have a table with millions of rows in it and I want to keep only the latest 4 months rows. I have the following table with column names as
ERROR_IND
FEED_ID
QUEUE_ID
FEED_DT_TM
I have written
delete * from table where (sysdate-(feed_dt_tm))>= 120.
But, Is writing a script increases the efficiency than querying the delete statement.
After performing the delete operation, I need to partition the table. I am confused on how to handle it as I am very new to this stuff. Please advise me on this issue.
Thanks In advance