Incorrect MySQL client version lazarus / 16-Databases ---------------------------------------------------------------------- jollytall · 2023-04-08 10:36 I have few programs that use MySQL, though I did not use them for some time. Now I tried again, and they all fail with error: Code: Text  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i TMySQL57Connection can not work with the installed MySQL client version: Expected (5.7), got (3.1.20).Indeed all my settings are for 5.7: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i uses  lazutf8,  mysql57conn, mysql57dyn, sqldb;var  MainSQLConnection_ : tMYSQL57Connection;but as far as I know, my MySQL is also 5.7: Code: Text  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i ~$ mysql Welcome to the MySQL monitor.  Commands end with ; or \g.Your MySQL connection id is 4Server version: 5.7.29 MySQL Community Server (GPL)What do I do wrong? What could change since the last use? Thanx ---------------------------------------------------------------------- balazsszekely · 2023-04-08 10:54 @jollytall If you're absolutely sure that MySQL version is 5(I'm not) , then Set SkipLibraryVersionCheck property to True and see what happens. ---------------------------------------------------------------------- jollytall · 2023-04-08 11:54 Thanks, I am almost sure, as this one worked for some time and also if you see my OP, it gives the version as 5.7.29, however the error message was about the MySQL Client, not the server. I tried your idea, and it went through the Connect := true; step, but it gave me an error with the Query ExecSql: EDatabaseError, Database not assigned. So, something is clearly wrong. ---------------------------------------------------------------------- balazsszekely · 2023-04-08 12:00 Quote from: jollytall on April 08, 2023, 01:54:02 pmThanks, I am almost sure, as this one worked for some time and also if you see my OP, it gives the version as 5.7.29, however the error message was about the MySQL Client, not the server. I tried your idea, and it went through the Connect := true; step, but it gave me an error with the Query ExecSql: EDatabaseError, Database not assigned. So, something is clearly wrong. Maybe you have multiple version of MySQL installed? ---------------------------------------------------------------------- jollytall · 2023-04-08 12:56 I don't know. Attaches is the complete list of installed packages with "sql" in their name/description. I manually removed everything I could, but nothing helped. Where else could I look for it? ---------------------------------------------------------------------- jollytall · 2023-04-08 13:20 I found one thing: https://mariadb.com/kb/en/mariadb-connector-c-3-1-20-release-notes/ It says: QuoteNotable changes mysql_get_client_info()/mysql_get_client_version() now return the Connector/C specific version (instead of corresponding server version),so I guess this is why FPC/Lazarus sees 3.1.20 (connector version), instead of 5.7 (what is the server version). I am not sure, if this is also the reason why after switching off the version check it still does not work. Keep on trying. I will need to check if there is a FPC upgrade to handle this. EDIT: I checked it, and the MariaDB version is from the 7/Feb/2023, while on gitlab I do not see any update on mysql57conn in the last 2 years, so probably there is no new sw. I am still wondering why switching off the version check it still fails. ---------------------------------------------------------------------- jollytall · 2023-04-08 15:27 Sort of solved. The core of the problem was, as I noticed above, that MariaDB now gives back the client version, not the server version, so the Connect fails. Using SkipLibraryVersionCheck bypasses this problem. It would be good to fix it though. Then it still did not work, but that is an old problem, that a variable in the testing program was named SQLConnection and this is also the name of a property in tSQLTransaction so in a with statement it picked up the property not the variable. This I had once in the past, this is why I start the variables sometimes with My..., but now I forgot it in the test program and thought that it is still related to the original MariaDB problem. So, thanks for looking into it, but this part was my fault. And a third thing. I saw on gitlab that now there is support for 8.0 as well. I copied the mysql80conn and mysql80dyn files and the relevant updated .inc files, but I cannot add them to the uses. What else is needed to be changed? Thanks,