Index: generic/tdbcmysql.c
--- generic/tdbcmysql.c.orig
+++ generic/tdbcmysql.c
@@ -376,11 +376,16 @@ static const char *const TclIsolationLevels[] = {
     "serializable",
     NULL
 };
+
+/*
+Bug report: https://core.tcl-lang.org/tdbcmysql/info/9bf0e3e2e7
+Fixing commit: https://core.tcl-lang.org/tdbcmysql/info/e5b2587e70
+*/
 static const char *const SqlIsolationLevels[] = {
-    "SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED",
-    "SET TRANSACTION ISOLATION LEVEL READ COMMITTED",
-    "SET TRANSACTION ISOLATION LEVEL REPEATABLE READ",
-    "SET TRANSACTION ISOLATION LEVEL SERIALIZABLE",
+    "SET SESSION TRANSACTION ISOLATION LEVEL READ UNCOMMITTED",
+    "SET SESSION TRANSACTION ISOLATION LEVEL READ COMMITTED",
+    "SET SESSION TRANSACTION ISOLATION LEVEL REPEATABLE READ",
+    "SET SESSION TRANSACTION ISOLATION LEVEL SERIALIZABLE",
     NULL
 };
 enum IsolationLevel {
@@ -3732,7 +3737,18 @@ Tdbcmysql_Init(
 	    return TCL_ERROR;
 	}
 	mysql_library_init(0, NULL, NULL);
-	mysqlClientVersion = mysql_get_client_version();
+
+	/*
+	The only use of mysqlClientVersion in this in this program is to check that
+	it is >= 50100 and select "st_mysql_bind_50" or "st_mysql_bind_51" accordingly.
+	Since MariaDb 10.6.2 the client version (a lower number) is reported.
+	https://github.com/perl5-dbi/DBD-mysql/issues/333
+	(The current MariaDb version is over 10 at the time of this writing.)
+	Set the version manually to always select "st_mysql_bind_51".
+	*/
+
+	mysqlClientVersion = 50100;
+
     }
     ++mysqlRefCount;
     Tcl_MutexUnlock(&mysqlMutex);
