28.06.2020, 10:36
Quote:
But now i have the problem that if i sellect car 2 it give's me someone else car from db, is like i am selecting car database id not the menu car id. |
Also:
Code:
for(new i = 1; i <= cache_num_rows(); i++)
Code:
for (new i, rows = cache_num_rows(); i < rows; i++) //Or, even better yet: new rows; cache_get_row_count(rows); for (new i; i < rows; i++)
When you use cache_num_rows() in the statement part of the for() loop, it gets called every loop. When you assign it the way I did, cache_num_rows() is called once.
Also: https://forum.sa-mp.com/showpost.php...4&postcount=12
Also also, I highly recommend you to use threaded queries.
If your MySQL server would be lagging somehow, your entire server will freeze for everyone after using /v untill the results come in and are handled.