Raised This Month: $51 Target: $400
 12% 

[TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)


Post New Thread Reply   
 
Thread Tools Display Modes
danielkza
AMX Mod X Plugin Approver
Join Date: May 2007
Location: São Paulo - Brasil
Old 12-22-2008 , 01:44   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #21

Just kick the player in the query callback.
__________________

Community / No support through PM
danielkza is offline
Drak
Veteran Member
Join Date: Jul 2005
Old 12-22-2008 , 01:48   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #22

Quote:
Originally Posted by danielkza View Post
Just kick the player in the query callback.
Durrrrrrrrrrrrr. Lol, thanks.
__________________
Oh yeah
Drak is offline
Send a message via MSN to Drak
whosyourdaddy
Senior Member
Join Date: Apr 2008
Old 02-02-2009 , 03:19   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #23

kk what happens if u keep on getting
Code:
if ( failstate == TQUERY_CONNECT_FAILED )

cause of some reason im getting those here and there. is there something i can do to prevent it?
whosyourdaddy is offline
danielkza
AMX Mod X Plugin Approver
Join Date: May 2007
Location: São Paulo - Brasil
Old 02-02-2009 , 03:53   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #24

Quote:
Originally Posted by whosyourdaddy View Post
kk what happens if u keep on getting
Code:
if ( failstate == TQUERY_CONNECT_FAILED )

cause of some reason im getting those here and there. is there something i can do to prevent it?
Try printing the error string/number, it will tell you what went wrong.
__________________

Community / No support through PM
danielkza is offline
Hawk552
AMX Mod X Moderator
Join Date: Aug 2005
Old 02-02-2009 , 09:12   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #25

Quote:
Originally Posted by whosyourdaddy View Post
kk what happens if u keep on getting
Code:
if ( failstate == TQUERY_CONNECT_FAILED )

cause of some reason im getting those here and there. is there something i can do to prevent it?
danielkza is right. From what I hear, non-threaded connections can break up due to lack of activity, but if you're using a threaded query, the connection is made right when the query is called. We'd need to see the error to diagnose it.
__________________
Hawk552 is offline
Send a message via AIM to Hawk552
whosyourdaddy
Senior Member
Join Date: Apr 2008
Old 02-02-2009 , 13:28   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #26

Code:
[MYSQLX] Threaded query error, location: 1
[MYSQLX] Message: Can't connect to MySQL server on 'xx.xxx.xx.xxx' (10060) (2003)
[MYSQLX] Query statement: REPLACE INTO `wc3_player_race` ( `player_id` , `race_id` , `race_xp` ) VALUES ( '12429', '1', '78929'); 
[MYSQLX] Fail state: Connection Failed
i removed where its being located but xx.xx.xxx.xx has a real ip that has a succesfull connection
whosyourdaddy is offline
danielkza
AMX Mod X Plugin Approver
Join Date: May 2007
Location: São Paulo - Brasil
Old 02-02-2009 , 13:45   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #27

Quote:
Originally Posted by whosyourdaddy View Post
Code:
[MYSQLX] Threaded query error, location: 1
[MYSQLX] Message: Can't connect to MySQL server on 'xx.xxx.xx.xxx' (10060) (2003)
[MYSQLX] Query statement: REPLACE INTO `wc3_player_race` ( `player_id` , `race_id` , `race_xp` ) VALUES ( '12429', '1', '78929'); 
[MYSQLX] Fail state: Connection Failed
i removed where its being located but xx.xx.xxx.xx has a real ip that has a succesfull connection
No it does not. Check the error message of SQL_Connect. And by the error, i'm positive the connections is being rejected/not getting to the IP at all.
__________________

Community / No support through PM
danielkza is offline
whosyourdaddy
Senior Member
Join Date: Apr 2008
Old 02-02-2009 , 13:47   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #28

Quote:
Originally Posted by danielkza View Post
No it does not. Check the error message of SQL_Connect. And by the error, i'm positive the connections is being rejected/not getting to the IP at all.
SQL_connect works cause my regular queries dont give me any error messages, its just now and then my threaded queries give me error messages that connection has failed. is there a way i can make my query redo itself 5 times before quiting and sending me the error message, and other than threaded queries making a seperate connection whats the difference in using threaded queries from regular queries?

Last edited by whosyourdaddy; 02-02-2009 at 13:50.
whosyourdaddy is offline
minimiller
Veteran Member
Join Date: Aug 2007
Location: United Kingdom
Old 11-22-2009 , 18:23   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #29

sicko tutorial dude
ill be needing threaded queries pretty soon
<3
__________________
minimiller is offline
Send a message via MSN to minimiller
platzpatrone
Veteran Member
Join Date: Apr 2007
Location: Germany
Old 12-03-2009 , 05:37   Re: [TUT] SQLx - the newest AMXX SQL driver set (advantages and usage)
Reply With Quote #30

great tuto! nice job ! very helpful here and there

send some
platzpatrone is offline
Reply



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 08:20.


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