Toad World® Forums

Automated Export to Excel with SYSDATE Toad for Oracle


#1

I have an automated query which runs each Monday and exports an excel file to a folder on our work server (I have tried on my local drive also). I would like to append the excel file with the run date. I was able to do this in Toad Data Point, but cannot figure out a way to do it from Toad for Oracle.

I tried the “Filename_%sysdate%” in the output file name, but an error comes up that says “cannot create file “Filename_1\31\2019.xlsx”. The system cannot find the path specified.”

Any help would be appreciated.


#2

Any of these would work:

Filename_%DATEFILE%.xlsx
Filename_%DATEFILE%_%TIMEFILE%.xlsx
Filename_%TIMEFILE%.xlsx

To see all of the variable name choices, right-click in the filename edit box and choose “Variables” in the popup menu. But only the “File” ones are going to make sure that your file names are valid.

-John


#3

That worked! Thank you so much.
I didn’t know the “variables” option was there. Very helpful!