Re: writing to text file
Date: Sun, 22 Jul 2001 06:57:27 GMT
Message-ID: <3B468CFC.3D60A739_at_exesolutions.com>
Thomas Kyte wrote:
> In article <3B45D984.54F7C478_at_attws.com>, "Daniel says...
> >
> >"Andrei V. Kirilenkov" wrote:
> >
> >> hi
> >> if you are using the standart SQL+ then use
> >> spool file_name
> >> Oracle will copy into file_name the SQL+
> >> output Brian Janko <brian_at_jankoNOnet.SPAMcom.INVALID> wrote in message
> >> news:0H517.2723$Pf4.313156_at_bin1.nnrp.aus1.giganews.com...
> >> > How can I get the results of several SQLPlus queries to Oracle to write
> >> > their results into a single tab-delimited text file?
> >> >
> >> > Thanks,
> >> > Brian
> >> >
> >> >
> >> >
> >
> >How do you spool a tab delimited file?
> >
> >Daniel A. Morgan
> >
>
> well, one answer would be goto technet and look it up. Its right there in the
> sqlplus guide ;)
>
> Another way would be to show you
>
> scott_at_8i> set colsep ' ' <<<=== thats a TAB in there
> scott_at_8i> set heading off
> scott_at_8i> set feedback off
> scott_at_8i> set embedded on
> scott_at_8i> set pagesize 10000
> scott_at_8i> spool foo.csv
> scott_at_8i> select * from emp;
> scott_at_8i> spool off
>
> --
> Thomas Kyte (tkyte_at_us.oracle.com) http://asktom.oracle.com/
> Expert one on one Oracle, programming techniques and solutions for Oracle.
> http://www.amazon.com/exec/obidos/ASIN/1861004826/
> Opinions are mine and do not necessarily reflect those of Oracle Corp
If I really cared I would have. I posted that question there so the person who asked the original question would get a full and complete answer.
Whenever I've needed to do it it has been within an application and I far prefer the flexibility and power of UTL_FILE.
Daniel A. Morgan Received on Sun Jul 22 2001 - 08:57:27 CEST
