I need to transfer data from Hive to MySQL.
Here is my sqoop command:
jdbc:mysql://mysqlserver --username username --password password --table test --columns "member_id,answer_id,answerer_id" -m 1 --export-dir /user/hive/warehouse/utils.db/test --input-fields-terminated-by \001 --lines-terminated-by \n --update-mode allowinsert
But, every time I run this command, data seems to be appended to the table but not overwrite the table.
So, is there any way that I can truncate MySQL table automatically when I run this sqoop command?