2
votes

I am just starting out with Delphi XE5 development and am having A LOT of trouble trying to connect to my mySQL server.

Using the TFDConnection i currently get this error:

[FireDAC][Phys][MySQL]-314. Cannot load vendor library [libmysql or libmysqld.dll]. The system cannot find the file specified...

I have already read the docs on this issue and i have:

  • Sourced the LIBMYSQL.DLL from a MySQL Server installation

  • Placed it in the bin directory of XE5 AND referenced it in FDDrivers.ini

I have also noticed that when i view FireDAC Links in XE5 it has TFDPhysMySQLDriverLink grayed out...

I can connect to SQLlite servers fine.

1
Set DriverName to 'MySQL'. Did you try to doubleclick on TFDConnection component?Sir Rufo
Yes i have set the DriverName and tried double-clicking TFDConnection component. No luck with that...Toby Flemming
Error message has been updated, accidentally posted wrong one the first time.Toby Flemming
Do you installed x86 or x64 libmysql.dll ? If x64, then you need x86.da-soft
@da-soft yes i installed x86 version. Do you know what else it could be?Toby Flemming

1 Answers

0
votes

I have also noticed that when i view FireDAC Links in XE5 it has TFDPhysMySQLDriverLink grayed out...

That's because the device cannot connect directly to the mySQL database. From my understanding, you're supposed to create a DataSnap server which will act as your middle tier. The DSServer will connect to the MySQL DB through FDConnection + FDQuery (note that the MySQL link will work here).

However, I am still stuck at connecting the mobile application to the DSServer. If you've figured out more, please share