Hive insert overwrite table xxx 与 insert into table xxx 区别

  • INSERT OVERWRITE will overwrite any existing data in the table or partition
  • INSERT INTO will append to the table or partition, keeping the existing data intact(完整无缺的).
    也就是说 overwrite会覆盖现有的数据,而into是直接将数据写入库。如果需要的是去重的数据,那么应该选择overwrite作为插入的方式。

你可能感兴趣的:(Hive)