29.07.2017, 19:28
My code is returning an empty string when being called.
It isn't doing this anywhere else, just when this piece of code is being called.
Код:
[20:09:37] Saving business 0 [20:09:37] (null)
PHP код:
stock SaveBusiness(i)
{
new string[512];
printf("Saving business %d", i);
mysql_format(conn, string, sizeof(string), "UPDATE `business` SET \
`EntranceX` = %f, \
`EntranceY` = %f, \
`EntranceZ` = %f, \
`EntranceR` = %f, \
`EntranceInt` = %d, \
`EntranceVW` = %d, \
`ExitX` = %f, \
`ExitY` = %f, \
`ExitZ` = %f, \
`ExitR` = %f, \
`ExitInt` = %d, \
`ExitVW` = %d, \
`Enterable` = %d, \
`Value` = %d, \
`EntranceCost` = %d, \
`Till` = %d, \
`Type` = %d, \
`Stock` = %d \
WHERE `BusinessID` = %d", \
BusinessData[i][bEntranceX],
BusinessData[i][bEntranceY],
BusinessData[i][bEntranceZ],
BusinessData[i][bEntranceR],
BusinessData[i][bEntranceInt],
BusinessData[i][bEntranceVW],
BusinessData[i][bExitX],
BusinessData[i][bExitY],
BusinessData[i][bExitZ],
BusinessData[i][bExitR],
BusinessData[i][bExitInt],
BusinessData[i][bEnterable],
BusinessData[i][bValue],
BusinessData[i][bEntranceCost],
BusinessData[i][bTill],
BusinessData[i][bType],
BusinessData[i][bStock],
i+1);
mysql_tquery(conn, string);
print(string); // [20:09:37] (null)
}