optimization - speed up an update join query in mysql -
i have 2 tables each of 1 hundred million rows, key1 , str_key both non-unique keys. following mysql query, according show engine innodb status, performing around 80 reads/sec, no updates yet. no other query running.
update table_r r, table_w w set r.key1=0 r.str_key=w.str_key
- is correct query take 100 million / 60 > 1 million seconds finish?
- how optimize query finish quickly?
whenever query slow, first thing make sure have index on columns mentioned in clause.
Comments
Post a Comment