Download MetaTrader 5

libmysql.dll on MT4 via Wine

To add comments, please log in or register
All activity at is clearly visible. Have a look at the Wall!
Shadi Akiki
Shadi Akiki 2014.02.15 19:07 


I'm trying to use the libmysql.dll in an EA, similar to

My setup is MT4 via Wine on Ubuntu (32 bit), and I only copied the libmysql.dll file into the MT4 libraries directory, no header files copied along.

The dll file is from the dev.mysql website

At mysql=mysql_init(mysql), I get "Unhandled exception 0x80000100"

How can I figure out what this exception is?


Michele Lazzarini
Michele Lazzarini 2014.02.15 22:37  
whroeder1 2014.02.16 01:06  
You've updated to build 6xx. All strings are now Unicode. Does your call accept Unicode or old ANSI?
Shadi Akiki
Shadi Akiki 2014.02.16 07:01  

@oddpip, thanks for the link. I posted my question there, and I'm updating from Wine 1.4 to 1.6 in case that'll help.

@WHRoeder, thanks for the hint. mysql_init is a function with an int parameter, not a string parameter, and there are no function calls to any function in the libmysql.dll library prior to the mysql_init function call. The article (Major MetaTrader 4 Build 600 Update Released - Articles - MetaQuotes Software Support Center) on page 17 suggests that ANSI versus Unicode is only relevant to function calls with string parameters. In any case, I don't see any option in Metaeditor to change the character encoding.

I'd like to highlight though that my question is about _how_ I can figure out what the exception code 0x80000100 stood for. e.g. is there a way to use the debugger to show more details? are there any logs that can show more details?

Shadi Akiki
Shadi Akiki 2014.02.16 09:16  
So I fixed this by downloading the portable zip file of Heidisql (8.3) and using the libmysql.dll file from there. I had read on some forum that it could be that the runtime of the dll file downloaded from the dev.mysql website (c connection 6.1) is mismatching with that used upon compilation of MT4
To add comments, please log in or register