I tried to use Micrsoft ADO 6.0 library and connect with ado to mysql. Here is my code :
Dim conn As ADODB.Connection
Dim rs As ADODB.Recordset
Dim sql As String
Set conn = New ADODB.Connection
conn.ConnectionString = "ODBC;Driver=MySQL ODBC 5.1 Driver;" & _ "SERVER=127.0.0.1;PORT=3306;DFLT_BIGINT_BIND_STR=1 ;" & _ "DATABASE=mybase;UID=myuser;PWD=mypwd"
conn.Open
But in this moment I receive an error - code -2147467259. This is tranlation from polish :
Generated by Microsoft OLE DB Provider for ODBC Drivers
Description [Microsoft][Driver manager ODBC] Can't find name of data source, and there is no preferred driver.
Mysql database is tunelled to localhost and I can read data in liked tables in access so connection string is good for 100% . I want to connect via ADO because I need to execute query that I cannot execute in linked table ( due to data conversion ).