[Mono-dev] MySql and Mono using System.Data.Common

Wael Zeenni bigzee at zeenni.net
Sun Apr 20 04:39:59 EDT 2008


Hey all,

I'm having some issues trying to get MySql to work with System.Data.Common. On my Windows 2003 server I'm running a test application and switching between MS SQL and MySql at runtime and everything works fine.

However, when I run my application in Mono, I keep getting the following error:


-----------------
Failed to find or load the registered .Net Framework Data Provider   'MySql.Data.MySqlClient'. () ()
  

Description: HTTP 500. Error processing request.  

Stack Trace:   
    
   

System.Configuration.ConfigurationErrorsException: Failed to find or load the registered .Net Framework Data Provider 'MySql.Data.MySqlClient'. () ()
  at System.Data.Common.DbProviderFactories.GetFactory (System.String providerInvariantName) [0x00000] 
  at _Default.btnLogin_Click (System.Object sender, System.Web.UI.ImageClickEventArgs e) [0x00000] 
  at System.Web.UI.WebControls.ImageButton.OnClick (System.Web.UI.ImageClickEventArgs e) [0x00000] 
  at System.Web.UI.WebControls.ImageButton.RaisePostBackEvent (System.String eventArgument) [0x00000] 
  at System.Web.UI.WebControls.ImageButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent (System.String eventArgument) [0x00000] 
  at System.Web.UI.Page.RaisePostBackEvent (IPostBackEventHandler sourceControl, System.String eventArgument) [0x00000] 
  at System.Web.UI.Page.RaisePostBackEvents () [0x00000] 
  at System.Web.UI.Page.ProcessRaiseEvents () [0x00000] 
  at System.Web.UI.Page.InternalProcessRequest () [0x00000] 
  at System.Web.UI.Page.ProcessRequest (System.Web.HttpContext context) [0x00000] 
    _____  

  Version information: Mono Version: 2.0.50727.42; ASP.NET   Version: 2.0.50727.42 
-------------------------


The MySql.Data is registered correctly in my GAC. Like I said, it works in Windows, but not in OpenSUSE 10.3. Can anyone please help me as I have to develop a cross OS, cross DB web application and this is kind of hindering my efforts.

Also, according to this page on the mono-project.com website: http://www.mono-project.com/BaseClass_Provider_Factory

It says that as of now, only the following providers can be accessed:


* System.Data.SqlClient   
* System.Data.Odbc 
But I'm not sure when that page was last updated.

Can anyone please help me?

Thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20080420/c8c2296b/attachment.html 


More information about the Mono-devel-list mailing list