| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> comp.databases.oracle -> Re: how to Spool results from SQL plus
You can do it like this:
VAR SPOOLFILENAME VARCHAR2(30)
COLUMN SPOOLFILENAME NEW_VALUE SPOOLFILENAME
SELECT to_char(sysdate, 'YYMMDD') || '_anything.txt' AS SPOOLFILENAME FROM DUAL;
SPOOLFILENAME
SPOOL &SPOOLFILENAME
...
"Mario Horvat" <mario.horvat_at_vz.htnet.hr> wrote in message news:<c512v5$inv$1_at_sunce.iskon.hr>...
> I want to spool results from sql+ query to txt file.
> txt file should have name like YYMMDD_anything.txt, where YYMMDD is actual
> date.
>
> Can somebody tell me how to write this?
>
> Thanks in advance.
Received on Wed Apr 07 2004 - 11:40:25 CDT
![]() |
![]() |