Lost connection during server query

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
mierlp
Posts: 29
Joined: Thu 26 Jan 2006 08:34
Location: Nederlands

Lost connection during server query

Post by mierlp » Mon 29 Jun 2009 20:37

hi,

In runtime i get for one query the message : ''Lost connection during
server query''. The other 20 query components on my datamodule
don't have this problem.

The error occurs when do a search. The search code i use for this
form is the same as on other forms.

When starting the apps .exe the application will be terminated when
do the search option.

What causes this problem and how to fix it.

Regards Peter

mierlp
Posts: 29
Joined: Thu 26 Jan 2006 08:34
Location: Nederlands

Post by mierlp » Mon 29 Jun 2009 21:48

The complete message is:

Project x raised exeption class EMYSQLException with message ''lost connection to mysql server during query''

When using ''Trace info'' in the Run menu from delphi i get the following
message :

Project x raised exeption class EMYSQLException with message
#HY000 unknown thread id: 980

eduardosic
Posts: 387
Joined: Fri 18 Nov 2005 00:26
Location: Brazil

Post by eduardosic » Mon 29 Jun 2009 22:19

mierlp wrote:The complete message is:

Project x raised exeption class EMYSQLException with message ''lost connection to mysql server during query''

When using ''Trace info'' in the Run menu from delphi i get the following
message :

Project x raised exeption class EMYSQLException with message
#HY000 unknown thread id: 980
Please, send more information:

What version of:
MySQL
MyDAC
Delphi or C++

Dimon
Devart Team
Posts: 2910
Joined: Mon 05 Mar 2007 16:32

Post by Dimon » Tue 30 Jun 2009 06:55

To solve the problem try to use the Disconnected mode.
You can find more detailed information about it in the "Working in an Unstable Network" topic of MyDAC help.

eduardosic
Posts: 387
Joined: Fri 18 Nov 2005 00:26
Location: Brazil

Post by eduardosic » Tue 30 Jun 2009 11:24

mierlp wrote:The complete message is:

Project x raised exeption class EMYSQLException with message ''lost connection to mysql server during query''

When using ''Trace info'' in the Run menu from delphi i get the following
message :

Project x raised exeption class EMYSQLException with message
#HY000 unknown thread id: 980
i found the bug " unknown thread " in a specific version of mydac 4

if you are using MyDAC 4, the best choise is upgrade to MyDAC 5 and use LocalFailOver to avoid LostConnection. disconnectedModel is a great tecnology.

Post Reply