The query below seems to take about 20 seconds to execute and because it's run multiple times in a single transaction it's affecting the the performance badly.
[update table1
set column3 = 'new_str'
where column1||','||column2 in
(select table1.column1||','||column2
from table1
join table2 on table1.column1 = table2.column1
where table2.column4 = 'value4'
and table1.column2 = 'value2'
and column3 = 'old_str')]
table 1
column1 - char (12) - primary key
column2 - char (30) - primary key
column3 - char (25)
table2
column1 - char (12) - primary key (foreign key in table 1)
column4 - char (12)
The above tables have about 1009578 and 1082555 records.