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: Oracle 8 updates from flat files - how

Re: Oracle 8 updates from flat files - how

From: Tim & Suzan Twombly <tim.suz_at_mediaone.net>
Date: Tue, 22 Dec 1998 21:58:57 -0500
Message-ID: <36805C71.D63274BE@mediaone.net>


Greg,
We have done this using the UTL_FILE utility for the read, and attempting to insert the record using a standard INSERT. In the EXCEPTIONS section, we specify WHEN DUP_VAL_ON_INDEX and do an UPDATE in that case... in our case it worked and performed pretty well. Good luck.

Tim Twombly
Stride Rite Corp.

Greg Drew wrote:

> I have an Oracle8 database which needs to be periodically updated with
> records pulled from an ASCII flat file provided by an external source.
> I've about gone blind perusing the SQL*Loader documentation, and can
> only find ways to append new records. Unfortunately, the file contains
> both new records and updates to existing ones. I can of course write
> code to parse the data and then query the DB to find out if the record
> exists, and then insert or update as appropriate, but my intuition tells
> me that there must be a better way. Does anyone have any ideas?
> --GDD


Received on Tue Dec 22 1998 - 20:58:57 CST

Original text of this message

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