I need to pass information to mysql using the command Insert but i am using VBA for excel and i need 70 fields of a table . So when i use conexao.Execute ("Insert into dados_anterior (COD_GERENCIA_NEGOCIOS,) values('" & CODGERENCIANEGOCIOS & "')") but its 70 fileds and the command stay too long and i can´t read it in vba ...
What should I do to send information to 70 fields in a table using the comand INSERT , but the line of the command stay too long....
Helo. I am using VBA for excel. How can I declare cm? when i write cm.execute what is going to happen? After doing this how can i use the command insert to send values to a mysql server using cm?
I use append to ??
Here is any example of how to declare a ado command object.
dim cm as ADODB.Command
and when you execute the cm you will be running the stored procedure that you specified and pass the values to the stored procedure. The stored procedure will do what you want on your mysql. So if your procedure appends the data, it will append the parameter values.
The stored procedure are stored inside your database.