I new to mySQL so don't shoot my if my question is easy to answer. I'm using VB to connect to a mySQL server and I can't get the connection to timeout. Why do I want to do exactly? Connect to server (max timeout of 5 seconds) if within 5 seconds I don't get a valid response from the server -> connection fails
How do I do this: When I call the api_mysql_connect api I set TMYSQL.options.connection_timeout = 5 Result: If I try to connect to an IP that isn't up (no host on that IP) => connect api times out after about 21 seconds If I try to connect to an IP that is UP but has no mySQL server listening to the mySQL port but another service listing to that port (used a dummy server that accepts connections but never sends data back) => connect api never times out (killed the app after about 20 minutes). >From what I can see OR I'm doing something wrong to set the timeout OR there is a bug within the connect API Public Declare Function API_mysql_connect Lib "libmysql.dll" Alias "mysql_connect" (ByRef TMYSQL As API_MYSQL, ByVal host As Long, ByVal user As Long, ByVal Passwd As Long) As Long Dirk. --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php