Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: export to ascii file

Re: export to ascii file

From: Lamar Spells <lspells_at_mindspring.com>
Date: 1997/05/02
Message-ID: <33695f39.2404977@news.mindspring.com>#1/1

I think there are some important questions that must be asked here in order to suggest a proper solution:

(1) What volume of data are you talking about? 100 Records, 1000 Records or 1000000 Records?

(2) What are you going to do with these records? Are your going to load them into another database, Oracle or otherwise? Are you going to provide this data to another system as a part of some sort of file based interface?

I once needed to a utility to do this sort of thing... The data was to be moved from an Oracle 7.1.6 database on HP-UX to an IBM mainframe for loading into a DB2 database as well as sent to other Oracle sites. I am not just talking about 1000 or 10000 records-- I am talking about __MILLIONS__ of records.

We wound up creating a program (which has about a million options) to (1) select the data using array processing and write it to an output file and (2) generate a control file that sqlldr or the DB2 load utility could use to load the data back. In order to do this, we obtained some sample code from Oracle and hacked it to do what we wanted. I am a little fuzzy on the details-- this has been about 1.5 years ago.

Thanks,
Lamar Spells
lspells_at_mindspring.com

"Daniel A. Morgan" <dmorgan_at_exesolutions.com> wrote:

>> I would like to know how or where I might find information on how
>> to export a table to an ascii file in ORACLE (for example, in SYBASE
>> I would use the following:
>>
>> bcp databaseName..tableName out dataFile -c .....
>
>A simple way, from SQL*Plus would be as follows:
>
>spool c:\temp\textfile.txt
>select * from mytable;
>spool off
>
>This will create an ASCII text file.
>
>Daniel A. Morgan
Received on Fri May 02 1997 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US