# Deleting or updating data with dboutput

**URL:** <https://forum.cloverdx.com/t/deleting-or-updating-data-with-dboutput/68>\
**Category:** CloverDX Platform\
**Created:** [July 16, 2007, 12:00am UTC](https://forum.cloverdx.com/t/deleting-or-updating-data-with-dboutput/68 "2007-07-16T00:00:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![oldforum](https://avatars.discourse-cdn.com/v4/letter/o/13edae/32.png) [@oldforum](https://forum.cloverdx.com/u/oldforum)\
**Post date:** [July 16, 2007, 12:00am UTC](https://forum.cloverdx.com/t/deleting-or-updating-data-with-dboutput/68/1 "2007-07-16T00:00:00Z")

</div>

Hi !

I want to transfer data from a table (table A) to another table (table B : same metadata) on other Oracle instance.

I use DATAINTERSECTION component to :  
- only insert new rows from table A to table B  
- updating rows of table B which haved changed  
- deleting rows of table B which have been deleted in table A.

How can I delete or update rows with cloverETL and with DBOUTPUT component ?

Thanks a lot.

---

<div class="post-metadata">

**Author:** ![oldforum](https://avatars.discourse-cdn.com/v4/letter/o/13edae/32.png) [@oldforum](https://forum.cloverdx.com/u/oldforum)\
**Post date:** [July 16, 2007, 8:23am UTC](https://forum.cloverdx.com/t/deleting-or-updating-data-with-dboutput/68/2 "2007-07-16T08:23:44Z")

</div>

Hello !

DBOutputTable can taky any SQL/DML command - including delete.

Use “sqlQuery” or “sqlCode” to provide something like this:  
“delete where \<key\_field\>=?”

And use “cloverFiedls” to select which field (its value) from Clover should be used in place of the “?”.

See this simple example:  
--------------------------------  
  
  
  
--------------------------------

---

<div class="post-metadata">

**Author:** ![ntmoyer](https://avatars.discourse-cdn.com/v4/letter/n/ad7895/32.png) [@ntmoyer](https://forum.cloverdx.com/u/ntmoyer)\
**Post date:** [August 7, 2007, 1:50pm UTC](https://forum.cloverdx.com/t/deleting-or-updating-data-with-dboutput/68/3 "2007-08-07T13:50:47Z")

</div>

do the fields passed to the cloverfields need to be in the order of the ?'s or does it matter?

---

<div class="post-metadata">

**Author:** ![avackova](https://avatars.discourse-cdn.com/v4/letter/a/65b543/32.png) [@avackova](https://forum.cloverdx.com/u/avackova)\
**Post date:** [August 9, 2007, 9:36am UTC](https://forum.cloverdx.com/t/deleting-or-updating-data-with-dboutput/68/4 "2007-08-09T09:36:00Z")

</div>

you can use fieldMap attribute to specify the exact mapping between clover and db fields
