From b3ffd0200ac7bb6a60b785c1e6b19a6c89a7e3a3 Mon Sep 17 00:00:00 2001 From: Christian Date: Wed, 3 Mar 2021 21:28:31 +0100 Subject: [PATCH] tested on dev, could not update time properly, adding table name and removing quotes causes the update queries to work --- RaceTimer/scripting/unloze_racetimer_redux.sp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/RaceTimer/scripting/unloze_racetimer_redux.sp b/RaceTimer/scripting/unloze_racetimer_redux.sp index ee75d2ff..e08e38b9 100644 --- a/RaceTimer/scripting/unloze_racetimer_redux.sp +++ b/RaceTimer/scripting/unloze_racetimer_redux.sp @@ -510,9 +510,9 @@ public void FinishedStageRaceZone(int client) int stage = player_stage[client]; char sQuery[g_dLength]; if (l_iZoneCount < 2) - Format(sQuery, sizeof(sQuery), "UPDATE `zetimer_table` SET `%s` = '%s', name = '%s' WHERE steam_auth = '%s' and LENGTH(`%s`) >= LENGTH('%s') and STRCMP(`%s`, '%s') > 0", g_cMapname, sTime, sEscapedName, sSID, g_cMapname, sTime, g_cMapname, sTime); + Format(sQuery, sizeof(sQuery), "UPDATE unloze_racetimer_css.zetimer_table SET `%s` = '%s', name = '%s' WHERE steam_auth = '%s' and LENGTH(`%s`) >= LENGTH('%s') and STRCMP(`%s`, '%s') > 0", g_cMapname, sTime, sEscapedName, sSID, g_cMapname, sTime, g_cMapname, sTime); else - Format(sQuery, sizeof(sQuery), "UPDATE `zetimer_table` SET `%sS%i` = '%s', name = '%s' WHERE steam_auth = '%s' and LENGTH(`%sS%i`) >= LENGTH('%s') and STRCMP(`%sS%i`, '%s') > 0", g_cMapname, stage, sTime, sEscapedName, sSID, g_cMapname, stage, sTime, g_cMapname, stage, sTime); + Format(sQuery, sizeof(sQuery), "UPDATE unloze_racetimer_css.zetimer_table SET `%sS%i` = '%s', name = '%s' WHERE steam_auth = '%s' and LENGTH(`%sS%i`) >= LENGTH('%s') and STRCMP(`%sS%i`, '%s') > 0", g_cMapname, stage, sTime, sEscapedName, sSID, g_cMapname, stage, sTime, g_cMapname, stage, sTime); if (StrEqual(g_csTime_record[client], "0.000")) {