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

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Update existing rows at import

Re: Update existing rows at import

From: William Beilstein <BeilstWH_at_obg.com>
Date: Wed, 28 Mar 2001 13:41:44 -0800
Message-ID: <F001.002DABB0.20010328134550@fatcity.com>

You can't query or modify the same table as the trigger is firing on (The old mutating table problem). What you could do is set up a temp table with a before insert trigger which would query the other table and take the appropriate actions, this would solve you having to run a separate procedure after the temp table was loaded. Or load the temp table and run a procedure. When your done with your insert, truncate the temp table and your ready for your next load.

>>> Winnie_Liu_at_infonet.com 03/28/01 04:06PM >>>

Can you have a before-insert trigger on your table to do whatever you want and then use conventional sqlldr to load it? winnie

"Helmut Daiminger" <hdaiminger_at_vivonet.com> on 03/28/2001 12:38:10 PM

Please respond to <hdaiminger_at_vivonet.com>

To: "Oracle DBA List \(Lazy DBA\) \(E-mail\)" <oracledba_at_quickdoc.co.uk>,

      "Oracle List \(Telelist\) \(E-mail\)" <ORACLE-L_at_fatcity.com>, "Joe
      Sawyer \(E-mail\)" <jsawyer_at_traffic.com>, "Frach Karsten \(E-mail\)"
      <karsten.frach_at_gmx.de>, <lem_at_gedas.de>
cc:

Hi!

Is there a tool available that allows me to read data from a comma-delimited
flat file into Oracle and if a row already exists, updates that record. If the row does not exist, it should insert a new record into the table.

Looks to me like SQL*Loader can't do this.

How could this be done?

This is 8.1.6 on Win2k.

Thanks,
Helmut



Think you know someone who can answer the above question? Forward it to them!
to unsubscribe, send a blank email to oracledba-unsubscribe_at_LAZYDBA.com to subscribe send a blank email to oracledba-subscribe_at_LAZYDBA.com Visit the list archive: http://www.LAZYDBA.com/odbareadmail.pl Tell yer mates about http://www.farAwayJobs.com
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com 
-- 
Author: 
  INET: Winnie_Liu_at_infonet.com 

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: William Beilstein
  INET: BeilstWH_at_obg.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Wed Mar 28 2001 - 15:41:44 CST

Original text of this message

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