Re: IMPORT DATA FROM TXT FILE
Date: Thu, 01 Jul 2004 07:56:39 +0200
Message-ID: <opsaf2spqrm0et4w_at_news.online.de>
Hi
Am Wed, 30 Jun 2004 23:36:36 GMT schrieb MARA80 <maragiunta_at_email.it>:
> Hi, I'm discovering Oracle 8i Database just now and I'm trying to
> praticize
> the best I can.
> But I'm at beginnings and everything seems to me very hard.
> I have to import in a Oracle DB a txt file (formatted) and I have to
> create
> a table with it.
[Quoted] > Which is the right code to solve this problem?
I know 3 possibilities:
1)
Look up SQL*Loader in the ORACLE documentation.
This is the best solution in my opinion if you
have big data chunks of "good" (homogeneous) data
and the import can be done manually.
2)
Import the txt file into Excel or Access and then
transfer it via ODBC into ORACLE.
Easy but not very robust with big data chunks or
bad data.
3)
Put the file on the ORACLE Server machine.
Then write a stored procedure and read the
files data using the utl_file package and insert
the records via "insert into ...".
This is the best solution if you have bad data and
the procedure is not allowed to stop. You may write
a logfile, perform other "post read" actions ...
-- Crisis? What Crisis? ---------------------------------------------------- f_r_a_n_k_a_t_k_o_n_a_d_d_o_t_n_e_tReceived on Thu Jul 01 2004 - 07:56:39 CEST