6 messages in com.mysql.lists.win32connection issue
FromSent OnAttachments
Mark Mchugh26 Jul 2005 02:58 
Daniel da Veiga26 Jul 2005 06:52 
J.R. Bullington26 Jul 2005 07:07 
Daniel da Veiga26 Jul 2005 07:16 
PF: MySQL26 Jul 2005 07:22 
Mike Hillyer26 Jul 2005 07:30 
Subject:connection issue
From:Mark Mchugh (mark@yahoo.com)
Date:07/26/2005 02:58:21 AM
List:com.mysql.lists.win32

Hi,

I am using the following connection, which i use when my application starts

Set connMySQL = New ADODB.Connection connMySQL.ConnectionString = "DRIVER={mySQL ODBC 3.51 Driver};" _ & "SERVER=192.168.0.55;" _ & "DATABASE=test;" _ & "UID=root;" _ & "PWD=;" _ & "OPTION=" & 1 + 2 + 8 + 32 + 2048 + 16384

connMySQL.CursorLocation = adUseClient

connMySQL.Open

and then in any other form, i use this to access the datebase

Set rs = New ADODB.Recordset rs.ActiveConnection = connMySQL rs.Open sqlstr, connMySQL, adOpenStatic, adLockOptimistic

so, for example, if i start my application, and leave it running for a while ( doing nothing ) and then try use a funtion to access the database, it does not work. I presume this is because the connection has timed out?

is there a better way of handling this? i dont think its wize just in increase the timeout on the database?

thanks

Mark