我有两个mysql表,
table_A = 2500000+(行) table_B = 6000000+(行)
我需要从table_B中的数据更新table_A中的行(使用多线程应用程序)
最快的方法是什么
选项A
update table_b b (select col_a,col_b from table_a where col_c=%s) b set a.col_a=b.col_a, a.col_b=b.col_b flag='C' where col_c=%s
选项B
data=select col_a,col_bfrom table_a where col_c=%s
update table_b set col_a=%s,col_b=%s,flag='C' where col_c=%s
选项C
左连接table_b with table_a