Hi,
we want to access data via a SQL Anywhere ADO.net driver. The issue is that this driver has slightly different versions on different servers and developer machines, while the package should be the same across the servers.
The version info, as found in machine.config is e. g. as follows:
<add name="SQL Anywhere 12 Data Provider" invariant="iAnywhere.Data.SQLAnywhere" description=".Net Framework Data Provider for SQL Anywhere 12" type="iAnywhere.Data.SQLAnywhere.SAFactory, iAnywhere.Data.SQLAnywhere.v3.5, Version=12.0.1.31523, Culture=neutral, PublicKeyToken=f222fc4333e0d400" />
<add name="SQL Anywhere 12 Data Provider" invariant="iAnywhere.Data.SQLAnywhere" description=".Net Framework Data Provider for SQL Anywhere 12" type="iAnywhere.Data.SQLAnywhere.SAFactory, iAnywhere.Data.SQLAnywhere.v3.5, Version=12.0.1.34573, Culture=neutral, PublicKeyToken=f222fc4333e0d400" />
It seems that the ADO.net connection manager references the exact version of the driver in its "Qualifier" property, which is e. g.
iAnywhere.Data.SQLAnywhere.SAConnection, iAnywhere.Data.SQLAnywhere.v3.5, Version=12.0.1.3473, Culture=neutral, PublicKeyToken=f222fc4333e0d400
This property is not available for configurations.
I tried to edit the machine.config file to contain:
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="SQL Anywhere 12 Data Provider" publicKeyToken="f222fc4333e0d400" culture="neutral" />
<bindingRedirect oldVersion="12.0.1.0-12.0.1.65534" newVersion="12.0.1.34573" />
</dependentAssembly>
</assemblyBinding>
</runtime>
where the newVersion value matches the version installed on the machine. But this does not seem to be used, and I get the same error as without this entry if the version in the Qualifier property does not exactly match the version installed on the machine:
Error: Microsoft.SqlServer.Dts.Runtime.DtsCouldNotCreateManagedConnectionException: Could not create a managed connection manager.
This error does not occur if the version info exactly matches the version of the driver installed.
Any idea how I could get this running?
Frank