Hello,
I am trying to run a Stored Procedure in Excel. I need to connect to SQL using ODBC. Has anyone got some code to do this and to run a Stored Procedure?
What references do I need in my VBA Project?
Printable View
Hello,
I am trying to run a Stored Procedure in Excel. I need to connect to SQL using ODBC. Has anyone got some code to do this and to run a Stored Procedure?
What references do I need in my VBA Project?
You can add a reference to MS ActveX Data Objects Library 2.x This will allow you to use ADO to connect to your db.
You can execute SPs by using a Command Object.