Raised This Month: $ Target: $400
 0% 

Mysql handle returning 0 on query problem


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
SaintK
Veteran Member
Join Date: Mar 2004
Old 02-27-2006 , 11:40   ok this is a little more info on the issue
Reply With Quote #8

i changed the code abit so i could see better what was going on

Code:
get_user_name(id,clientname,31)     get_user_authid(id,usersteam,31)     get_user_name(id,user_id,31)         server_print("[Logger-ClientAuth-1] ClientSteamid is: %s",usersteam)     server_print("[Logger-ClientAuth-1] ClientName is: %s",clientname)         new checkid[500]     format(checkid,499,"SELECT * FROM `savednames` WHERE `steamid` = '%s'", usersteam)       server_print("[Logger-ClientAuth-1] Sending sql string %s",checkid)     result = dbi_query(dbc,checkid)

in the console i got back


couldn't exec banned.cfg
Adding master server 69.28.151.162:27010
Adding master server 207.173.177.11:27010
[Logger-ClientAuth-1] ClientSteamid is: STEAM_ID_LAN
[Logger-ClientAuth-1] ClientName is: [DumB]SteamSucks
[Logger-ClientAuth-1] Sending sql string SELECT * FROM `savednames` WHERE `steamid` = 'STEAM_ID_LAN'
L 02/27/2006 - 163:15: [MYSQL] Invalid result handle 0
L 02/27/2006 - 163:15: [AMXX] Displaying debug trace (plugin "sqltest.amxx")
L 02/27/2006 - 163:15: [AMXX] Run time error 10: native error (native "dbi_num_rows")
L 02/27/2006 - 163:15: [AMXX] [0] sqltest.sma::client_authorized (line 70)

as you can see the actual select string was correct and in mysql i used the same string and got back one result so why is amx mod telling me that the result handle is 0 ie no results when it truely is a hit
here is mysql direct result below

Showing rows 0 - 0 (1 total, Query took 0.0006 sec) SQL-query:
SELECT *
FROM `savednames`
WHERE `steamid` = 'STEAM_ID_LAN'
LIMIT 0 , 30

any more ideas people before this totally gives me a brain melt down.
SaintK is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 20:17.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode