Unless PostgreSQL is extremely clever, this query effectively prevents the use of an index on the date column. You should use something like (MSSQL syntax, untested)
delete from table where column < DateAdd(day,-60,getdate());
Jenda
Enoch was right!
Enjoy the last years of Rome.
In reply to Re^2: CGI Program To Delete Old Data From MySQL Table?
by Jenda
in thread CGI Program To Delete Old Data From MySQL Table?
by Milti
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |