Re: Dump table to CSV file - how?
Date: 1998/01/15
Message-ID: <01bd217c$30ef6aa0$92806ac6_at_compaq>#1/1
Steve
Here is some code which may be what you are after for a single table :
set termout off --switch off output to screen set echo off --switch off echo of sql set pages 0 --stop page feeding set feed off --switch off feedback of rows returned
spool x.sql
select fkey||','||recid||','||abs1
from tempload
/
spool off
set pages 300
set feed on
set echo on
set termout on
Try it and see what it does for you.
Regards
Mike
<a href="mailto:mike_deans_at_hotmail.com">mike_deans_at_hotmail.com</a> <a href="mailto:mike_deans_at_compuserve.com">mike_deans_at_compuserve.com</a> <a href="mailto:mdeans_at_teleport.com">mdeans_at_teleport.com</a>
Steven C. Kondolf <skondolf_at_hatespam.frontiernet.net> wrote in article
<34b78fb5.797123_at_news.frontiernet.net>...
> I've been using Oracle applications for 3 years but have just begun
> learning sql, plsql, forms, etc.
>
> I need to write a plsql script that will take 7 or 8 tables and export
> them to a file in csv format. I can open each table in Browser and
> save them this way but would rather have a script available that I can
> run via sql plus.
>
> Is there a way to do this? I'm using sql plus 3.3 and personal oracle
> lite. Sorry if this question is real simple, I just haven't been able
> to find a way to do it. Thanks in advance.
>
> Regards,
> Steve
> skondolf_at_hatespam.frontiernet.net
> skondolf_at_hatespam.compuserve.com
>
> *** email addresses altered to foil spammers !! ***
> *** Remove hatespam. from address before sending ***
>
Received on Thu Jan 15 1998 - 00:00:00 CET