PC Review


Reply
Thread Tools Rate Thread

DbProviderFactories and multiple versions of connector FAILS

 
 
Jeff Jarrell
Guest
Posts: n/a
 
      12th Oct 2007
provider = DbProviderFactories.GetFactory(invariantName);

This FAILS when I have multiple versions of a connector installed. The message is something along the lines of "may not be installed" but thats not it.

Here is an excerpt from my machine config. As you can see I have MANY versions of MySql. I wouldn't do this but I have one commerical tool (codesmith, mysql provider) that requires a specific version and it is Not the current one. And it would seem over-time, the end users would not be paying attention to uninstalling old versions.

I suppose provide something in the app.config for codesmith for the 5.07 version and leave this as is. Any idea what that would look like?

jeff

<DbProviderFactories>
<add name="Odbc Data Provider" invariant="System.Data.Odbc" description=".Net Framework Data Provider for Odbc" type="System.Data.Odbc.OdbcFactory, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="OleDb Data Provider" invariant="System.Data.OleDb" description=".Net Framework Data Provider for OleDb" type="System.Data.OleDb.OleDbFactory, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="OracleClient Data Provider" invariant="System.Data.OracleClient" description=".Net Framework Data Provider for Oracle" type="System.Data.OracleClient.OracleClientFactory, System.Data.OracleClient, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add name="SqlClient Data Provider" invariant="System.Data.SqlClient" description=".Net Framework Data Provider for SqlServer" type="System.Data.SqlClient.SqlClientFactory, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<!-- commented because
provider = DbProviderFactories.GetFactory(invariantName)
doesn't work if there is more than ONE possibility)
<add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=5.0.3.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
<add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=5.1.3.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
<add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=5.0.7.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
-->
<add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=5.0.8.1, Culture=neutral, PublicKeyToken=c5687fc88969c44d" />
</DbProviderFactories>






 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Outlook Connector fails? tpcolson Microsoft Outlook Installation 10 28th Sep 2009 05:50 PM
Outlook Connector fails after first Send/Receive CY Microsoft Outlook Discussion 0 16th Mar 2009 10:18 PM
Outlook Connector fails to install Carter Microsoft Outlook Discussion 3 3rd Feb 2009 06:52 PM
Outlook Fails to Start after Connector Install =?Utf-8?B?RXJpYw==?= Microsoft Outlook Discussion 1 3rd Sep 2007 08:20 PM
Notes Connector Send Fails Kevin Kleinfelter Microsoft Outlook Interoperability 3 18th May 2004 08:39 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:04 AM.