在SPARK / JAVA计划中创建HIVE表是错误的

时间:2022-07-31 20:51:47

I am tyring to create a Hive table from Spark program using hive context.

我正在使用hive上下文从Spark程序创建一个Hive表。

CREATE TABLE

ROW FORMAt ..

by '~' STORED AS TEXTILE"

通过'〜'存储为纺织品“

I am receiving the following error when this statement was hit.

在发表此声明时,我收到以下错误。

Can someone help me in resolving this?

有人可以帮我解决这个问题吗?

Exception in thread "main" org.apache.spark.sql.execution.QueryExecutionException: FAILED: SemanticException Unrecognized file format in STORED AS clause: 'TEXTILE'
        at org.apache.spark.sql.hive.client.ClientWrapper$$anonfun$runHive$1.apply(ClientWrapper.scala:499)
        at org.apache.spark.sql.hive.client.ClientWrapper$$anonfun$runHive$1.apply(ClientWrapper.scala:484)
        at org.apache.spark.sql.hive.client.ClientWrapper$$anonfun$withHiveState$1.apply(ClientWrapper.scala:290)
        at org.apache.spark.sql.hive.client.ClientWrapper.liftedTree1$1(ClientWrapper.scala:237)
        at org.apache.spark.sql.hive.client.ClientWrapper.retryLocked(ClientWrapper.scala:236)
        at org.apache.spark.sql.hive.client.ClientWrapper.withHiveState(ClientWrapper.scala:279)
        at org.apache.spark.sql.hive.client.ClientWrapper.runHive(ClientWrapper.scala:484)
        at org.apache.spark.sql.hive.client.ClientWrapper.runSqlHive(ClientWrapper.scala:474)
        at org.apache.spark.sql.hive.HiveContext.runSqlHive(HiveContext.scala:605)
        at org.apache.spark.sql.hive.execution.HiveNativeCommand.run(HiveNativeCommand.scala:33)
        at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult$lzycompute(commands.scala:58)
        at org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult(commands.scala:56)
        at org.apache.spark.sql.execution.ExecutedCommand.doExecute(commands.scala:70)
        at org.apache.spark.sql.execution.SparkPlan$$anonfun$execute$5.apply(SparkPlan.scala:132)
        at org.apache.spark.sql.execution.SparkPlan$$anonfun$execute$5.apply(SparkPlan.scala:130)
        at org.apache.spark.rdd.RDDOperationScope$.withScope(RDDOperationScope.scala:150)
        at org.apache.spark.sql.execution.SparkPlan.execute(SparkPlan.scala:130)
        at org.apache.spark.sql.execution.QueryExecution.toRdd$lzycompute(QueryExecution.scala:55)
        at org.apache.spark.sql.execution.QueryExecution.toRdd(QueryExecution.scala:55)
        at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:145)
        at org.apache.spark.sql.DataFrame.<init>(DataFrame.scala:130)
        at org.apache.spark.sql.DataFrame$.apply(DataFrame.scala:52)
        at org.apache.spark.sql.SQLContext.sql(SQLContext.scala:817)
        at com.comcast.emm.vodip.Viper2.LegalDemand.main(LegalDemand.java:84)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at org.apache.spark.deploy.SparkSubmit$.org$apache$spark$deploy$SparkSubmit$$runMain(SparkSubmit.scala:731)

1 个解决方案

#1


1  

There is a spelling mistake in the query. please make sure to correct it to TEXTFILE instead of TEXTILE.

查询中存在拼写错误。请确保将其更正为TEXTFILE而不是TEXTILE。

#1


1  

There is a spelling mistake in the query. please make sure to correct it to TEXTFILE instead of TEXTILE.

查询中存在拼写错误。请确保将其更正为TEXTFILE而不是TEXTILE。