Ador.recordset with MySQL

I am trying to load data into the third-party grid (exontrol), using the command below.
            cStmt="Select * from compte"
            cString = "Provider=MSDASQL.1;Persist Security Info=False;User ID=root;Password=finger4;Data Source=FingerFinanceA10;Initial Catalog=fingerfinance"
            rs = new oleautoclient("ador.recordset")
            rs.open(cStmt, cString,3,3)
                        
            oGrid = form.activex1.nativeObject
            oGrid.ColumnAutoResize = false
            oGrid.ContinueColumnScroll = false
            oGrid.datasource = rs

I am getting this error message
Error:  OLE Dispatch Exception:  The recordset must support the bookmarks. ( Supports( adBookmark ) = True )

It looks like it has something to do with cursortype, cursorlocation. I am not really sure.
The same example works in SQL Server (with a connection string point to SQL server of course),

How can I rewrite my open method to meet this requirement.
Omer-PitouAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Dave BaldwinFixer of ProblemsCommented:
First, if you really are using MySQL and not MS SQL, you need to instal the MySQL ODBC driver.  http://dev.mysql.com/downloads/connector/odbc/

Example code can be found on these pages:
http://dev.mysql.com/doc/connector-odbc/en/connector-odbc-examples.html
http://dev.mysql.com/doc/connector-odbc/en/connector-odbc-examples-programming.html
0
Omer-PitouAuthor Commented:
I have my odbc driver installed. I can connect to the database without any problem.
For that specific component, I  need a recorset using ador.recordset which is the one supported so far.
0
Dave BaldwinFixer of ProblemsCommented:
MSDASQL has nothing to do with MySQL.
0
10 Tips to Protect Your Business from Ransomware

Did you know that ransomware is the most widespread, destructive malware in the world today? It accounts for 39% of all security breaches, with ransomware gangsters projected to make $11.5B in profits from online extortion by 2019.

Omer-PitouAuthor Commented:
That is the provider parameter that comes with the connection string. I have been using that connection string to connect to the database. The problem is the recordset generated should include bookmarks, something like that.
http://www.connectionstrings.com/mysql-connector-odbc-5-2/
0
Dave BaldwinFixer of ProblemsCommented:
I think you are still connecting to a MS SQL database, not MySQL.  The connection strings on that page ALL include a reference to the MySQL ODBC provider while yours does not.  "Persist Security Info" and "Initial Catalog" are not used by the MySQL ODBC driver either.
0
Omer-PitouAuthor Commented:
I fixed that, but still getting the same message
Error:  OLE Dispatch Exception:  Current Recordset does not support bookmarks. This may be a limitation of the provider or of the selected cursortype.
0
Omer-PitouAuthor Commented:
This is my connection string
cString = "Provider=MSDASQL; Driver={MySQL ODBC 5.3 Driver}; Server=localhost; Data Source=fingerfinanceA10; User=root;Password=finger4; Database=fingerfinance; option=3"
0
Omer-PitouAuthor Commented:
This solved my problem
rs = new oleautoclient("ador.recordset")
rs.cursorLocation = 3
rs.open(cStmt, cString,3,3)
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Omer-PitouAuthor Commented:
To resolve this, cursorLocation has to be set before the open method
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
MySQL Server

From novice to tech pro — start learning today.