June 9, 2006 at 8:58 am
Hi, i am new to sql server 2000. I have created a stored procedure and i want to store results in an excel file. any help will be appreciated. Thanks in advance.
June 9, 2006 at 9:19 am
There are several ways to store the output in excel.
The two easiest are
1. In query Analyzer set your Output to File and your ouput format to CSV (Tools->Options->Results will create a file you can open in Excel
2. Even easier is to set the output to Text and output format to Tab then select your output and paste into an open excel worksheet.
Other methods include writing an excel macro to connect to the SQL Server and execute the stored procedure - you can use the ADO connection, command and Recordset objects.
Good luck
S
June 9, 2006 at 9:28 am
Additionally you can use dts to call the stored procedure, and save as an excel file
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy