Timeout error when searching for a string in a table.

Timeout error when searching for a string in a table.

Postby emp51302 » Thu 10 Nov 2011 15:48

I am trying to search for a string in a table with 100 thousand and more records. It is a TEXT datatype field. I am getting timeout issues. Below is the stack trace error.

Please help!!!

Code: Select all
A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond


Stack Trace:


[SocketException (0x274c): A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond]
   System.Net.Sockets.Socket.Receive(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags) +6206572
   System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size) +134

[IOException: Unable to read data from the transport connection: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.]
   System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size) +300
   Devart.Common.a.b(Byte[] A_0, Int32 A_1, Int32 A_2) +59

[TimeoutException: Server did not respond within the specified timeout interval.]
   Devart.Common.a.b(Byte[] A_0, Int32 A_1, Int32 A_2) +138
   Devart.Common.au.c(Byte[] A_0, Int32 A_1, Int32 A_2) +156
   Devart.Common.t.e(Byte[] A_0, Int32 A_1, Int32 A_2) +66

[MySqlException (0x80004005): Lost connection to MySQL server during query]
   Devart.Data.MySql.bh.a(Exception A_0) +36
   Devart.Common.t.e(Byte[] A_0, Int32 A_1, Int32 A_2) +138
   Devart.Data.MySql.bk.a(Byte[] A_0, Int32 A_1, Int32 A_2) +622
   Devart.Data.MySql.bk.a() +26
   Devart.Data.MySql.bk.d() +33
   Devart.Data.MySql.u.a(af[]& A_0, Int32& A_1) +84
   Devart.Data.MySql.u.a(Byte[] A_0, Int32 A_1, Boolean A_2) +76
   Devart.Data.MySql.a1.e() +110
   Devart.Data.MySql.a1.o() +36
   Devart.Data.MySql.MySqlCommand.InternalExecute(CommandBehavior behavior, IDisposable stmt, Int32 startRecord, Int32 maxRecords) +1202
   Devart.Common.DbCommandBase.InternalExecute(CommandBehavior behavior, IDisposable stmt, Int32 startRecord, Int32 maxRecords, Boolean nonQuery) +19
   Devart.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior, Boolean nonQuery) +451
   Devart.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior) +6
   System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader() +12
   Devart.Data.Linq.Provider.DataProvider.ExecuteQuery(CompiledQuery compiledQuery, Object[] parentArgs, Object[] userArgs, Object lastResult) +859

[LinqCommandExecutionException: Error on executing DbCommand.]
   Devart.Data.Linq.LinqCommandExecutionException.CanThrowLinqCommandExecutionException(String message, Exception e) +59
   Devart.Data.Linq.Provider.DataProvider.ExecuteQuery(CompiledQuery compiledQuery, Object[] parentArgs, Object[] userArgs, Object lastResult) +3477
   Devart.Data.Linq.Provider.DataProvider.Devart.Data.Linq.Provider.IProvider.Execute(Expression query) +88
   Devart.Data.Linq.DataQuery`1.System.Linq.IQueryProvider.Execute(Expression expression) +29
   System.Linq.Queryable.Count(IQueryable`1 source) +243
   
[/code] :?:
emp51302
 
Posts: 46
Joined: Fri 19 Aug 2011 20:57

Postby StanislavK » Tue 15 Nov 2011 17:45

Sorry for the delay. Apparently, the command timeout expired when executing the command. The default timeout used for MySQL commands is 30 seconds. To extend this period, please set the 'Default Command Timeout' property of the connection string. You can also set this property to 0, in which case there will be no time limit for command execution.

Please tell us if this helps.
StanislavK
Devart Team
 
Posts: 1710
Joined: Thu 03 Dec 2009 10:48


Return to dotConnect for MySQL