Page 2 of 2
Re: sql istrinimas
Posted: 2011 Mar 24 13:24
by newb
Nu gal, bet anyway visur raso.
Re: sql istrinimas
Posted: 2011 Mar 24 15:29
by aurimasko
o kuo skiriasi replace ir insert?
Re: sql istrinimas
Posted: 2011 Mar 24 15:56
by newb
Insertas visalaik naujus idedines, o replace idedines naujus jei tokiu paciu nera. Seip is pavadinimo nesunku suprast...
Re: sql istrinimas
Posted: 2011 Mar 24 16:13
by aurimasko
o dar klausimas ne į šią temą: kaip sužinot žaidėjo protokolą? t.y. ar jis 47 ar 48 protokolo
Re: sql istrinimas
Posted: 2011 Mar 24 17:01
by aaarnas
Pasinaudojant dproto pagalba. Plačiau apie tai rasi dp_test.sma faile (kartu su dproto būna jis)
Re: sql istrinimas
Posted: 2011 Mar 24 17:40
by aurimasko
vistiek
L 03/24/2011 - 17:39:08: [..amxx] You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '0', '0', '0', '0', '0', '0')' at line 1
meta
Re: sql istrinimas
Posted: 2011 Mar 24 18:40
by aaarnas
Padaryk log_amx(szQuery) prie kiekvieno. Ir nukopijuok ką loguose parašys.
Re: sql istrinimas
Posted: 2011 Mar 24 19:22
by aurimasko
manau, kad error čia:
Code: Select all
formatex( szQuery, 299, "REPLACE INTO `client_pult` `ip`, `model`, `skin`, `jumps`, `status`, `bullet`, `foot`, `camera` VALUES '%s', '%d', '%d', '%d', '%d', '%d', '%d', '%d'", ip, g_status[id][4], g_status[id][6], g_status[id][1], g_status[id][5], g_status[id][3], g_status[id][2], g_status[id][7]);
Nes visur kitur rodo normaliai, tik šita errorina.
Re: sql istrinimas
Posted: 2011 Mar 24 19:56
by newb
Manau querys turi atrodyt taip
Code: Select all
"REPLACE INTO `table` (ip, amount) VALUES ('%s', '%d')"
Re: sql istrinimas
Posted: 2011 Mar 24 21:46
by aurimasko
Štai ką rašo loguose:
SELECT:
Code: Select all
L 03/24/2011 - 21:42:11: [.amxx] SELECT * FROM `client_pult` WHERE `ip`='78.57.135.185'
DELETE:
Code: Select all
L 03/24/2011 - 21:42:11: [.amxx] DELETE FROM `client_pult` WHERE `ip`='89.117.93.165'
Ir dar būna tokie:
Code: Select all
L 03/24/2011 - 21:42:11: [.amxx] 0', '0', '0')L 03/24/2011 - 21:42:11: [.amxx] You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '0', '0', '0')' at line 1
Tai kame replės, kad kai kuriems net įrašo į mysql duomenis, kitiem neįrašo. Eilutė tokia kaip newb parodė.
-- 2011 Kov 26 18:58 --
L 03/26/2011 - 17:56:53: [menu.amxx] REPLACE INTO `client_pult` (ip, model, skin, jumps, status, bullet, foot, camera) VALUES (78.61.29.226, 0, 0, 0, 0, 0, 0, 0)
L 03/26/2011 - 17:56:53: [menu.amxx] You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '.29.226, 0, 0, 0, 0, 0, 0, 0)' at line 1
dabar tokį errorą meta.