Good Morning All,
I’m a new TOAD & SQL user and trying to learn as fast as I can
I inherited some queries that need to run and save as a .txt file daily, I’m wondering if there’s a way to automate the ‘save as’ and file location? for example…is there a set command or statement i can insert in my sql that would automate the process?
check into the SPOOL SQL*Plus command. It causes everything to go to a spooled file. You will also have to use some SET commands so that you don’t get the query sent to the file also.
By the way this is an SQL question and not a Toad question and should thus go to the TOADSQL list.
This could be treated as a Toad question too. Take a look at actions and
commandline information in the help file and also look at Toad Online in the
Help menu. Gives you a lot of resources to find information ont Toad.
I must admit that for creating a text file sqlplus is enough. But maybe you want
to create a spreadsheet. I guess that you read the text file into a spreadsheet
to manipulate it further?
Groetjes,
Wim
On Thu, Mar 10, 2011 at 16:33, Erwin Rollauer
wrote:
check into the SPOOL SQL*Plus command. It causes everything to go to a
spooled file. You will also have to use some SET commands so that you
don't get the query sent to the file also.
By the way this is an SQL question and not a Toad question and should thus
go to the TOADSQL list.
ETRG (Erwin The Retired Guy)
________________________________________