Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL ------> Excel Table Transfer - Fastest method 1

Status
Not open for further replies.

netcashin

Programmer
Nov 13, 2000
159
US
I am needing to transfer a table I have in a SQL database to excel spreadsheet programatically. I know I can export it out of the database through the enterprise manager, but I need to do it through my program.

I can do it through VB, but it is kind of slow. What I would really like to do,is be able to do the transfer through a stored procedure, but I have been unable to find any way to do that.

Anyone's thoughts would be appreciated.

Thanks
 
I haven't done it, but you should be able to run the Export Wizard to export to Excel, then save it as a DTS package. Then you'll be able to run that DTS package programmatically.

Robert Bradley

 
For a total SQL solution, you should use DTS.

However, you could write an Active-X application that references the spreadsheet, then call it's methods using sp_OACreate, sp_OAMethod, etc, within the stored procedure.

Tom
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top