View | Details | Raw Unified | Return to bug 34027
Collapse All | Expand All

(-)a/misc/cronjobs/cleanup_database.pl (-1 / +4 lines)
Lines 408-413 if ($pZ3950) { Link Here
408
408
409
if ($pLogs) {
409
if ($pLogs) {
410
    print "Purging records from action_logs.\n" if $verbose;
410
    print "Purging records from action_logs.\n" if $verbose;
411
    for (0..10000){
412
        $dbh->do(q{ INSERT INTO action_logs (user,timestamp) VALUES (52,"2022-01-01 09:00:00") });
413
        $dbh->do(q{ UPDATE action_logs SET timestamp = "2020-01-01 10:00:00" ORDER BY action_id DESC LIMIT 1 });
414
    }
411
    my $log_query = q{
415
    my $log_query = q{
412
            DELETE FROM action_logs
416
            DELETE FROM action_logs
413
            WHERE timestamp < date_sub(curdate(), INTERVAL ? DAY)
417
            WHERE timestamp < date_sub(curdate(), INTERVAL ? DAY)
414
- 

Return to bug 34027