From 61fd2c6d61a264a967c72ce1ce552fc1e8804d6d Mon Sep 17 00:00:00 2001 From: Daniel Maya Date: Fri, 8 Sep 2017 13:04:19 +0200 Subject: [PATCH] Delete old tgraph_source data --- pandora_server/util/pandora_db.pl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pandora_server/util/pandora_db.pl b/pandora_server/util/pandora_db.pl index 12acb3a5f8..892bdd273a 100644 --- a/pandora_server/util/pandora_db.pl +++ b/pandora_server/util/pandora_db.pl @@ -431,6 +431,9 @@ sub pandora_purgedb ($$) { WHERE date < CURDATE() - $conf->{'_num_past_special_days'} AND date > '0001-01-01'"); } } + + # Delete old tgraph_source data + db_do ($dbh,"DELETE FROM tgraph_source WHERE id_graph NOT IN (SELECT id_graph FROM tgraph)"); } ###############################################################################