Bug #67387 ODBC 5.2.2 and ODBC 5.1.11 Windows 64 Bit causes MS SQL Server 2008 R2 crash
Submitted: 26 Oct 2012 15:13 Modified: 8 Jun 2013 6:21
Reporter: Christoph Ingenhaag Email Updates:
Status: No Feedback Impact on me:
None 
Category:Connector / ODBC Severity:S3 (Non-critical)
Version:5.2.2, 5.1.11 OS:Windows (Server Standard FE SP 2)
Assigned to: Bogdan Degtyariov CPU Architecture:Any
Tags: Linked server connection, MS SQL Server 2008 R2, ODBC

[26 Oct 2012 15:13] Christoph Ingenhaag
Description:
When I submit a catalog in the MS SQL Server 2008 R2 Managment Studio linked server assistant GUI to connect with a MYSQL Server the SQL Server service crashes.

Windows Eventlog:
Fehlerhafte Anwendung sqlservr.exe, Version 2009.100.1600.1, Zeitstempel 0x4bb6b40b, fehlerhaftes Modul myodbc5w.dll, Version 5.2.2.0, Zeitstempel 0x50585b99, Ausnahmecode 0xc0000005, Fehleroffset 0x0000000000026e03, Prozess-ID 0x20e4, Anwendungsstartzeit 01cdb374bed725b9.

How to repeat:
Install mysql-connector-odbc-5.2.2-winx64.msi. Create a system DSN with the ODBC Wizard. Start the MS SQL Server Management Studio, create a new linked server (Provider MSDASQL) and submit a catalog. When you hit the OK Button, SQL Server crashes. If you omit the catalog, a connection will be established.
[26 Oct 2012 15:59] Christoph Ingenhaag
same behaviour with ODBC driver 5.1.11

Windows eventlog:
Fehlerhafte Anwendung sqlservr.exe, Version 2009.100.1600.1, Zeitstempel 0x4bb6b40b, fehlerhaftes Modul myodbc5.dll, Version 5.1.11.0, Zeitstempel 0x4f9b1ada, Ausnahmecode 0xc0000005, Fehleroffset 0x0000000000027983, Prozess-ID 0xd4c, Anwendungsstartzeit 01cdb38cf738b3b9.
[27 Oct 2012 9:10] Christoph Ingenhaag
The workaround is to omit the catalog in the linked server connection and use the MS SQL Server OPENQUERY syntax to query the MySQL Schema like
select * from openquery(LINKEDSERVERNAME, 'select * from SCHEMA.TABLE limit 1, 100')
[14 Nov 2012 9:40] Bogdan Degtyariov
Thanks for your report. We are trying to repeat the problem.
[27 Feb 2013 14:37] Andrew Monty
I can confirm this bug. When specifying a catalog, the following error occurs:

-----------------------------------------------------------------------------
Faulting application name: sqlservr.exe, version: 2009.100.2500.0, time stamp: 0x4dfb6221
Faulting module name: myodbc5a.dll, version: 5.2.4.0, time stamp: 0x51018aed
Exception code: 0xc0000005
Fault offset: 0x00000000000250fd
Faulting process id: 0x870
Faulting application start time: 0x01ce14f67beea3a3
Faulting application path: C:\Program Files\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQL\Binn\sqlservr.exe
Faulting module path: C:\Program Files\MySQL\Connector ODBC 5.2\ANSI\myodbc5a.dll
Report Id: bae1cfb3-80e9-11e2-bbf7-9a143e4c3d05
--------------------------------------------------------------------------

Leaving the catalog field empty results in a successful connection to the remote MySQL Server.
[8 May 2013 6:21] Bogdan Degtyariov
Can you please describe step by step how exactly you submitted the catalog in MSSQL 2008R2 Management Studio.
Thanks.
[9 Jun 2013 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".