CommandTimeOut Error : ASP.net 2.0 DataSource controls and MySQL

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for MySQL
Post Reply
robbhill
Posts: 3
Joined: Tue 28 Nov 2006 21:54
Contact:

CommandTimeOut Error : ASP.net 2.0 DataSource controls and MySQL

Post by robbhill » Tue 28 Nov 2006 22:09

I am running MySQL Server 5.0 along with ASP.Net 2.0 with VS 2005.

I am getting a timeout error when reaching 30 seconds between mysql and the datasource control.

I have defined the control in my aspx page like so...

"
datasourcemode="DataSet"
providerName="CoreLab.MySql" />



In my webconfig file my connectionstring is like this:




In my vb.net code behind..I populate the datasource control with a string like so:

DataSource.SelectCommand = "queryString"

The mysql query takes about 70 seconds from mysql to run....asp.net timesout at 30..which I believe is the defaul for the command timeout..

I cannot figure out how to change the command timeout...

I am still running my trial version..

Please help.

robbhill
Posts: 3
Joined: Tue 28 Nov 2006 21:54
Contact:

Post by robbhill » Wed 29 Nov 2006 13:56

I Do not have timeout as an option to choose from...

these are what im importing:
Am I missing something?

Imports System.Data.SqlClient
Imports System.data
Imports System.Drawing
Imports System.Configuration.AppSettingsSection
Imports System.IO
Imports System.Runtime.Serialization
Imports System.Diagnostics
Imports CoreLab.MySql

Alexey
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Post by Alexey » Wed 29 Nov 2006 14:36

Configuring SqlDataSource component topic is beyond the scope of our support program. Please refer to MSDN.
Last edited by Alexey on Wed 29 Nov 2006 15:01, edited 1 time in total.

robbhill
Posts: 3
Joined: Tue 28 Nov 2006 21:54
Contact:

Post by robbhill » Wed 29 Nov 2006 14:52

Actually I found a way around it.

Here is my code....


Protected Sub DataSource_Selecting(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.SqlDataSourceSelectingEventArgs) Handles DataSource.Selecting
e.Command.CommandTimeout = 200
End Sub


This changes the timeout on the command....when using a sqldatasource control.

Alexey
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Post by Alexey » Fri 08 Dec 2006 12:03

Good decision.

Post Reply