18.11.2017, 19:56
Hello, I have a problem in server_log. I have a timer that every 30 minutes check for logs to delete the old logs, but i get every time this errors:
The table `timeplayed' exist, i don't know why i get the error.
client2146 = my database name
code:
The table `timeplayed' exist, i don't know why i get the error.
client2146 = my database name
Код:
[17:23:50] Error ID: 1146, Error: Table 'client2146.timeplayed' doesn't exist [17:23:50] Callback: [17:23:50] gQuery: DELETE FROM `timeplayed` WHERE `unixtime` < '1505661830' [17:23:50] ==================================================================== [17:23:50] ==================================================================== [17:23:50] Error ID: 1146, Error: Table 'client2146.antifraudaraport' doesn't exist [17:23:50] Callback: [17:23:50] gQuery: DELETE FROM `antifraudaraport` WHERE `time` < '1510845830' [17:23:50] ==================================================================== [17:23:50] ==================================================================== [17:23:50] Error ID: 1146, Error: Table 'client2146.blockedaccounts' doesn't exist [17:23:50] Callback: [17:23:50] gQuery: UPDATE `blockedaccounts` SET `unblock`='0',`key`='',`linkexpire`='0' WHERE `unblock` < '1510586630' [17:23:50] ==================================================================== [17:23:50] ==================================================================== [17:23:50] Error ID: 1146, Error: Table 'client2146.blockedaccounts' doesn't exist [17:23:50] Callback: [17:23:50] gQuery: UPDATE `blockedaccounts` SET `linkexpire`='0',`key`='' WHERE `linkexpire` < '1510845830' [17:23:50] ====================================================================
Код:
new test[256]; mysql_format(SQL, test, sizeof(test), "DELETE FROM `timeplayed` WHERE `unixtime` < '%d'", (gettime() - 86400*60)); mysql_tquery(SQL, test, "", ""); mysql_format(SQL, test, sizeof(test), "DELETE FROM `antifraudaraport` WHERE `time` < '%d'", gettime()); mysql_tquery(SQL, test, "", ""); mysql_format(SQL, test, sizeof(test), "UPDATE `blockedaccounts` SET `unblock`='0',`key`='',`linkexpire`='0' WHERE `unblock` < '%d'", (gettime() - 86400*3)); mysql_tquery(SQL, test, "", ""); mysql_format(SQL, test, sizeof(test), "UPDATE `blockedaccounts` SET `linkexpire`='0',`key`='' WHERE `linkexpire` < '%d'", gettime()); mysql_tquery(SQL, test, "", "");