Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> way to delete records after a period of time if they meet criteria?
Hey all,
I know I could do this with a cron and a script, but I'm looking into if it can be done easily right from Oracle. I'm using Oracle 8i on a Unix Solaris box.
Simplified:
I have a table with records for name, item purchased, date entered, and
date paid. I want to delete the record if the item hasn't been paid for
in 5 days after entry.
So...
delete from tablename where datePaid is null and dateEntered < sysdate-5
Can I do that without a cron that runs once daily?
TIA
-- -- ~kaeli~ With her marriage, she got a new name and a dress. http://www.ipwebdesign.net/wildAtHeart http://www.ipwebdesign.net/kaelisSpaceReceived on Thu Jul 08 2004 - 08:33:17 CDT