20.03.2018, 16:03
Anyone can help me with the saving process here's the code
it ain't saving !
Код:
stock SaveBusiness() { for(new i; i <= MAX_BUSINESS; i++) { if(Business[i][Used]) { new DB_Query[1000]; mysql_format(Database, DB_Query, sizeof(DB_Query),"UPDATE `BUSINESS` SET `NAME` = %s, `TYPE` = %d, `PRODUCT` = %d, `FEE` = %d, `OWNER` = %d, `SAFE` = %d, `VW` = %d, `INT` = %d, `PRICE` = %d, `PosX` = %f, `PosY` = %f, `PosZ` = %f WHERE `ID` = %d LIMIT 1", Business[i][Name],Business[i][Type],Business[i][Product],Business[i][Fee],Business[i][Owner], Business[i][Safe],Business[i][Vw], Business[i][Int], Business[i][Price],Business[i][PosX],Business[i][PosY],Business[i][PosZ],i); mysql_tquery(Database, DB_Query); } } return 1; }