Getting NOT_SUPPORTED_COMMAND_WITHOUT_HIVE_SUPPORT while using Hudi

Getting NOT_SUPPORTED_COMMAND_WITHOUT_HIVE_SUPPORT while using Hudi

Getting the error when I try to execute spark sql.

Caused by: org.apache.spark.sql.AnalysisException: [NOT_SUPPORTED_COMMAND_WITHOUT_HIVE_SUPPORT] CREATE Hive TABLE (AS SELECT) is not supported, if you want to enable it, please set "spark.sql.catalogImplementation" to "hive".;\n\'CreateTable `spark_catalog`.`raw`.`raw_customers`, org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe, ErrorIfExists\n\n\tat org.apache.spark.sql.errors.QueryCompilationErrors$.ddlWithoutHiveSupportEnabledError(QueryCompilationErrors.scala:1806)\n\tat org.apache.spark.sql.execution.datasources.HiveOnlyCheck$.$anonfun$apply$4(rules.scala:466)

Answer

You have to enable Hive support for Spark.
Set this config in your spark val:

spark.conf.set("spark.sql.catalogImplementation", "hive")

Enjoyed this article?

Check out more content on our blog or follow us on social media.

Browse more articles