Toad World® Forums

Export to specific sheet in specific excel-file


#1

Hello everybody,

Is there a way to export a result to a specific Excel file and specify a sheet name?
I can export to Excel, even into active cells but I didn’t find a way to tell him into wich file and instance the data should be exported.
Any ideas?

Thanks,
Thomas


#2

Hello Thomas,

I assume you are using Toad for Data Analysis beta build 1.1.0.260

There is a way to export a table or result set to a specific Excel file, but not specify a sheet name. I will write an enhancement request for you and post the request number in this thread.

Here are the steps to export to a selected Excel file. You probably already know this, but I will include it anyway, in case other posters are interested in reading it.

Step 1) pick the table or result set you want to export. There are several ways to do this;
Use main menu item Tools->Export Wizard, put a checkmark next to the table name on the “Select Objects” window of the Data Export Wizard, and click Next;
or
Select a table in the Object Palette, right-click on the table name to bring up the context menu, and choose “Send To->Export Wizard”
or
From a Query result set, right-click on the Result set (the window you see at the bottom of the Query Builder window, Result Sets tab), and choose “Export->Export Wizard”.

Step 2) On the “Output Options” screen of the Data Export Wizard, in “Output Format” pane on the left-hand side of the wizard, choose “Excel File (2003)” from the drop-down list. (Choose other options as necessary, e.g. “Column names for first row”, “Add Excel worksheet if row limit reached”, etc.) Click Next. At this point you may see a warning that Excel has limits on the number of rows and columns supported. Acknowledge the warning and continue.

Step 3) Pick the desired columns on the Advanced Field Options screen of the Data Export Wizard. click Next.

Step 4) You wil see the Output Location screen of the Data Export Wizard. The “File” radio button should be pre-selected. There is a “…” button next to the filename field. You can use that button to save the export into an Excel file name of your choosing. Choose the directory and type in the desired file name, and click Finish.

You will see an “Export Finished” window showing export results. In this window, the file name (rightmost column) is shown as a hyperlink. You can click on the filename in this window to open it in Excel.

Click on OK to lose the “Export Finished” window, and voila.