The easiest way is to create a new query from the database window and set (Query | SQL Specific | Pass-Through). Set the ODBC connection string in the properties, and type the query using MySQL syntax. Such a query can be set as record source for a form, but will be read-only.
Based on your code, you can write any valid SQL into an existing query, including pass-through queries:
CurrentDb.QueryDefs("MyQue
ry").SQL = strSQL
Then, set the record source to that query. This is what I meant by “rewrite the QueryDef object's SQL on the fly.”
You can also use DAO or ADO techniques to produce a recordset, using JetSQL or pass-through syntax. It's really just a matter of providing a valid connection string. Some recordsets can be set to the form's recordset property after they have been created.
You seem to prefer ADO; the required properties are
.Properties("Jet OLEDB:ODBC Pass-Through Statement") = True
.Properties("Jet OLEDB:Pass Through Query Connect String") = <string>
See also on MSDB: ADO Provider Properties and Settings
http://msdn.microsoft.com/en-us/library/aa140022(office.10).aspx(search for "pass-through" in your browser, it's a long page)
You cannot directly write native (pass-through) SQL into a form's record source property, as there is no property to specify a connection string.
Good luck!
(°v°)