Excel - Update MySQL database using Excel VBA

Asked By Lane on 19-Jun-12 05:56 AM
Dear Excel experts,

I would like to use Excel VBA to update data on a database. I am using a we=
b database running MySQL. My Excel-sheet is collecting data in real-time. I=
want to get it to update database as data is being collected. May I ask th=
e experts here whether this is even possible with VBA?

Thank you very much for your help.


Greg Glynn replied to Lane on 07-Aug-12 08:45 PM
Hi Lane

abase. I am using a web database running MySQL. My Excel-sheet is collectin=
g data in real-time. I want to get it to update database as data is being c=
ollected. May I ask the experts here whether this is even possible with VBA=
? Thank you very much for your help.

It certainly is.  Which version of Excel are you running?  If it is Excel 2=
003 I recommend Conrad Carlberg's most Excellent book "Managing Data with M=
icrosoft Excel"

At any rate the first step is to install the ODBC drivers for MySQL
http://dev.mysql.com/downloads/connector/

Then you need to setup your connection using the MS ODBC Data Sources confi=
g.
odbcad32.exe  (Should be in your \Windows\System32 folder)

Then the fun begins.