Export SQL Results To Excel Using SQLPLUS
Here is quick tip on how to easily export SQL results into an excel file.
Step 1: Login into database using SQL PLUS
Step 2: Set markup using below command
SET MARKUP HTML ON
Step 3: Spool the output to a file.
SPOOL C:\TEMP\MYOUTPUT.XLS
Step 4: Run your SQL Query
SQL QUERY
Step 5: Set the Spool Off.
Step 6: Open the output XLS file to view the output.
Thanks for the tips
Good tip.
how to avoid break/titles per every 14 rows.
PROJECTNAME DESCRLONG
….
…..
….
PROJECTNAME DESCRLONG
I tried the above solution to send output of a query from sql*plus to an excel file, it works fine.
But column headings are appearing after every 15 rows in the excel sheet, i want the headings to appear once only, what can i do to get rid of this problem?
Great post. It helped me complete my work project.
Thanks so much,
Alice
how to create multiple tabs in one single file using spool command.
How to import the exported data in another PC?