ASP.NET is returning Unable to find the requested .Net Framework Data Provider when connecting to mysql database

If you are using asp.net + mysql database,you might receive the following error on the hosting server:

Unable to find the requested .Net Framework Data Provider.  It may not be installed.

To fix this issue, please do follow these steps:

1. In your local machine, please find and upload this file to your BIN folder:  Mysql.Data.dll

You will find it in places like C:\Program Files\MySQL\MySQL Connector Net 6.6.4\Assemblies  (Given that you already installed "MySQL .NET connector".

2. Edit your webconfig.  Assuming you're using version 6.6.4  (please make sure you use the correct version.)

 

<system.web>

      <compilation debug="true" urlLinePragmas="true">

                        <assemblies>

                                <add assembly="MySql.Data,Version=6.6.4, Culture=neutral,PublicKeyToken=C5687FC88969C44D"/>

                        </assemblies>

                </compilation>

</system.web>

<system.data>

    <DbProviderFactories>

      <add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL"    type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data,Version=6.6.4, Culture=neutral, PublicKeyToken=c5687fc88969c44d"/>

    </DbProviderFactories>

</system.data>
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

SQL server- network related or instance-specific error happened while connection establishing

  Instance-specific or network related error happening while connecting to SQL server   Please...

OleDB connection string examples

OleDB connection string examples MS Access (Jet) "PROVIDER=Microsoft.Jet.OLEDB.4.0;DATA...

Do you allow custom COM components?

Do you allow custom COM components? We are not offering to install the custom COM components...

Error when accessing a WCF services

Error when accessing a WCF services Error when accessing a WCF service: "IIS specified...

How to cache static contents to client with UseMaxAge?

You can consider to caches static contents to the client with UseMaxAge if your website has too...

Powered by WHMCompleteSolution