https://bugs.winehq.org/show_bug.cgi?id=46581
Bug ID: 46581 Summary: HeidiSQL generates OLE error when executing custom queries against MSSQL server. Product: Wine Version: 4.1 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: comsvcs Assignee: wine-bugs@winehq.org Reporter: wine@zootal.com Distribution: ---
HeidiSQL generates OLE error when executing custom queries against MSSQL server.
The program will run and open a connection to a MS SQL server. It will display data in the normal manner, table information, etc. It will allow updates to data in data grid.
However, if you try to run a custom query via the query tab, no matter you type in (valid query or not), it will generate an error:
OLE error 800401F0
It also gives the suggestion to install mdac28, and set mdac native_mdac, neither of which help. You have to have mdac install to get it to open a connection the server, so you would not get this far if mdac was not installed.
To duplicate: Create a clean wine prefix. Install mdac28, set native_mdac. I did this with winetricks:
sh winetricks mdac28 sh winetricks native_mdac
Run Heidisql. Connect to a Microsoft SQL Server. You should be able to connect, view data, etc. Click the Query tab. Enter a simple query, such as select * from <some table>. Execute the query. The error occurs immediately.
This line appears in console:
0054:err:ole:CoCreateInstanceEx apartment not initialised
This did not occur in wine versions from 3.0 through 3.14.
On a closely related topic, in wine 3.15 through 3.21, a similar error occurs when trying to open a connection to a MS SQL Server. This was apparently fixed with wine 4.0, in that now the error only occurs when trying to run a custom query as described above. Prior to wine 3.15, this worked just fine.
Slackware 14.2 64 bit. Tested in clean wine prefix, both 32 and 64 bit, with mdac28 and native_mdac via winetricks.