Hive:Error while compiling statement: FAILED: ParseException cannot recognize input near '<EOF>' '<

简介: Hive:Error while compiling statement: FAILED: ParseException cannot recognize input near '<EOF>' '<

Hive:Error while compiling statement: FAILED: ParseException cannot recognize input near '<EOF>' '<


一、Hive SQL 报错如下:

Error: Error while compiling statement: FAILED: ParseException line 79:17 cannot recognize input near '<EOF>' '<EOF>' '<EOF>' in subquery source (state=42000,code=40000)

二、查bug及解决:

Hive SQL 跟Oracle SQL 一样,允许嵌套格式:

-- 伪代码
select * 
from
(
    select * 
    from 
    example_tabel
    where 
    ***
    order by ***
) attention

老实说,一开始检查报错所在行数代码,未发现错误。

后单独执行嵌套在内层的代码,也顺利出结果。

之后发现,嵌套的内层的表一定要有别名,也就是示例代码中的表名 “attention” ,不然就会报上面的错误。

以上,问题解决~


相关文章
|
SQL HIVE
DataGrip连接Hive执行DDL操作报错:「FAILED: ParseException line 1:5 cannot recognize input near 'show' 'indexes' 'on' in ddl statement」
DataGrip连接Hive执行DDL操作报错:「FAILED: ParseException line 1:5 cannot recognize input near 'show' 'indexes' 'on' in ddl statement」
625 0
DataGrip连接Hive执行DDL操作报错:「FAILED: ParseException line 1:5 cannot recognize input near 'show' 'indexes' 'on' in ddl statement」
|
7月前
|
SQL 分布式计算 资源调度
[已解决]FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.MoveTask. Unable to
[已解决]FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.MoveTask. Unable to
352 0
|
SQL HIVE Python
Window10 pyhive连接hive报错:Could not start SASL: b‘Error in sasl_client_start (-4) SASL(-4)
Window10 pyhive连接hive报错:Could not start SASL: b‘Error in sasl_client_start (-4) SASL(-4)
682 0
Window10 pyhive连接hive报错:Could not start SASL: b‘Error in sasl_client_start (-4) SASL(-4)
|
SQL HIVE
HIVE Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.MoveTask. Directory hdfs://m
HIVE Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.MoveTask. Directory hdfs://m
287 0
HIVE Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.MoveTask. Directory hdfs://m
|
SQL 分布式计算 Hadoop
导入hive表Error: Error while compiling statement: FAILED: SemanticException No files matching path file
导入hive表Error: Error while compiling statement: FAILED: SemanticException No files matching path file
|
SQL HIVE
Hive 报错:Error: Error while compiling statement: FAILED: ParseException line 1:7 Failed to recognize
Hive 报错:Error: Error while compiling statement: FAILED: ParseException line 1:7 Failed to recognize
|
SQL Java Apache
hive_异常_01_(未解决)FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. org.apache.hadoop.hbase.HTableDescriptor.addFamily
一、异常现象 单独的 hadoop、hbase 、hive 都是正常的,但是在 hive 整合hbase 时,在 hive中输入以下建表语句, CREATE TABLE hbase_table_1(key int, value string) STORED BY 'org.
4653 0
|
存储 SQL 关系型数据库
mysql无法删除数据库:ERROR 1010 (HY000): Error dropping database(can't rmdir './hive/')
应用场景 搭建hadoop环境的时候,安装hive,需要绑定元数据存储地址,一般我们设置元数据存放地址在mysql,在mysql中建立数据库为hive,存储hive中的元数据,但是当我们把mysql修改了不区分大小写...
2476 0
|
7月前
|
SQL 数据采集 数据挖掘
大数据行业应用之Hive数据分析航班线路相关的各项指标
大数据行业应用之Hive数据分析航班线路相关的各项指标
211 1
|
2月前
|
SQL 分布式计算 Java
大数据-96 Spark 集群 SparkSQL Scala编写SQL操作SparkSQL的数据源:JSON、CSV、JDBC、Hive
大数据-96 Spark 集群 SparkSQL Scala编写SQL操作SparkSQL的数据源:JSON、CSV、JDBC、Hive
67 0