View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
ToniS ToniS is offline
external usenet poster
 
Posts: 18
Default Add columns of data from SQL

I have an excel spreadsheet with data in column A ONLY, based off of that
information I would like to add columns of data from SQL Server.
What would be the best method of doing that? Any examples would
be greatly appreciated, I am new to Excel/VBA. I was thinking of using
a Macro to execute the vba?

Ex. SpreadSheet


ID (colA) Store#(ColB) StoreName(ColC)

123 1 ABC Corp
333 3 Dan's Store
222 17 All Sports

I was able to create the connection sucessfully, and am familiar with how to
do
the Select statement, beyond that I am not sure how to add the data to the
Excel
Spreadsheet.

Again Column B and Column C would be added via the Macro based off
of the information in column A.

Any help would be greatly appreciated
ToniS