“INSERT INTO …” with SparkSQL HiveContext

前端 未结 6 1337
你的背包
你的背包 2021-02-05 05:32

I\'m trying to run an insert statement with my HiveContext, like this:

hiveContext.sql(\'insert into my_table (id, score) values (1, 10)\')

Th

6条回答
  •  粉色の甜心
    2021-02-05 05:55

    try this hiveContext.sql("insert into table my_table select 1, 10") if you haven't change your dynamic partition mode to nonstrict, you have to do this hiveCtx.setConf("hive.exec.dynamic.partition.mode", "nonstrict")

提交回复
热议问题