Dim db As New ADODB.Connection Dim cadena As String cadena = "DRIVER={MariaDB ODBC 3.1 Driver};SERVER=192.168.10.42;DATABASE=kmaleon;USER=root;PASSWORD=9027270020;PORT=3306;OPTION=" & (1 + 2 + 16 + 2048) & ";AllowZeroDateTime=True;ConvertZeroDateTime=True;" ' cadena = "DRIVER={MySQL ODBC 8.0 Unicode Driver};SERVER=192.168.10.42;DATABASE=kmaleon;USER=root;PASSWORD=9027270020;PORT=3306;OPTION=" & (1 + 2 + 16 + 2048) db.ConnectionString = cadena db.IsolationLevel = adXactReadUncommitted db.Open Dim createtable As String Dim destroytable As String createtable = _ "CREATE TABLE `jsc` (" & _ " `fecha` datetime NOT NULL DEFAULT '1899-12-30 00:00:00'," & _ " `numero` INT(11) NOT NULL DEFAULT '69'," & _ " `string` VARCHAR(50) NOT NULL DEFAULT 'level' COLLATE 'utf8_general_ci'," & _ " `id` INT(11) NOT NULL AUTO_INCREMENT," & _ " PRIMARY KEY (`id`) USING BTREE " & _ ")" & _ "COLLATE='utf8_general_ci' " & _ "ENGINE = InnoDB " & _ "AUTO_INCREMENT = 4;" destroytable = "drop table if exists jsc" db.Execute destroytable db.Execute createtable Dim rst As New ADODB.Recordset rst.CursorLocation = adUseServer rst.Open "select * from jsc", db, adOpenDynamic, adLockOptimistic ' create recordset without any value rst.AddNew rst.Update ' create recordset with only date and minimum date rst.AddNew rst!fecha = 0 rst.Update ' create recordset with only date rst.AddNew rst!fecha = CDate("3/11/2021") rst.Update ' create recordset with only text rst.AddNew rst!String = "test" rst.Update ' create recordset with only number rst.AddNew rst!numero = 99 rst.Update ' create recordset with all data filled rst.AddNew rst!fecha = CDate("10/12/2021") rst!String = "test filled" rst!numero = 1234 rst.Update rst.Close db.Close