Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: sql processing of local tables
> Is it possible to do SELECT statements on the server and write result
> tables to my C: drive and then use SQL to further process them there?
>
> I'm brand new to Oracle and SQL.
>
> I need to produce a flat file (ASCII fixed) for another agency from an
> Oracle 8i database residing on a web server in our DMZ.
>
> Because the format of the flat file is so different from our Oracle
> tables, I will need to do a quite a bit of massaging of the data.
You can use SQL*Plus on the client. With the spool command , SQL*Plus spools the result of the query in the specified output file. Example:
SQL> set heading off SQL> set pagesize 0 SQL> set feedback off SQL> spool c:\query_result.txt SQL> select a || ',' || b from my_table; (*)
024864,sdghsjkdgh
<something is written here>
SQL> spool off
(*) I used this form of query to have a comma separated list.
Regards,
Knut Received on Wed Mar 27 2002 - 06:07:15 CST