Thread: CopyManager(In/out) vs. delete/insert directly

CopyManager(In/out) vs. delete/insert directly

From
Emi Lu
Date:
Hello,

Two options for data (>1M), may I know which one better please?

(1) copyOut (JDBC copyManager)
      t1 into a.csv
      delete t2 where pk.cols in t1
      copyIn t2 from a.csv

(2) setautoCommit(false);
      delete t2 where pk.cols in t1;
      insert t2 select * from t1;

Thank you
Emi