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: Sqlldr Query

Re: Sqlldr Query

From: Daniel Morgan <damorgan_at_x.washington.edu>
Date: Wed, 08 Sep 2004 19:13:06 -0700
Message-ID: <1094696048.932999@yasure>


Ian wrote:

> Hallo,
>
> I am having trouble with the functionality of the sqlldr utility,
> specifically in regards to the insert, append, truncate, delete options.
>
> Task: Using sqlldr to update a number of tables from comma delimited files.
> This will happen on a daily basis. The comma delimited files contain new
> and updated record entries. The source data is from another transaction
> system which does not have a odbc driver available, hence daily extracts
> which are then ftp'd to the Oracle database server for update to the
> database which is used for reporting.
>
> Problem: Using append the new records are added however any record which is
> already in the database is discarded due to the primary key constraint.
> Using either truncate or delete blows away all records in the existing
> Oracle table leaving only the records from the upload in the table and the
> requirement is to keep all existing records + any new and updated records.
>
> Required behaviour: I would like all the records to be appended (new) and
> updated for those records which already exist in the database as one or more
> fields will have changed from the source transaction application.
>
> Thanks in advance for any helpful suggestions.
>
> Regards,
> Ian

I don't see why APPEND doesn't work for you given what you've stated. But it sounds to me like the amount of data is so small you should be thinking external tables.

What version of Oracle?

-- 
Daniel A. Morgan
University of Washington
damorgan_at_x.washington.edu
(replace 'x' with 'u' to respond)
Received on Wed Sep 08 2004 - 21:13:06 CDT

Original text of this message

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