fix the clan cleanup script!

main
hecht 13 years ago
parent f30196b6cb
commit 8e8a4b4471

@ -79,7 +79,9 @@ if ($i == 11) {
mysql_query('Update arena set einnahmen = 0');
// Inaktive Clans löschen (Clanräume werden automatisch gelöscht durch Fremdschlüssel)
mysql_query('delete from clan where id NOT IN(SELECT distinct(clan) from user )');
$sql = 'delete from clan where id NOT IN(SELECT distinct(clan) from user where clan is not null)';
//echo $sql . '<br>';
mysql_query($sql);
// Räume die Ticker auf (Massivster Datenmüll!!)
mysql_query('DELETE FROM clan_ticker WHERE date < TIMESTAMPADD(day, -7, now())');
mysql_query('DELETE FROM user_ticker WHERE date < TIMESTAMPADD(day, -7, now())');

Loading…
Cancel
Save