gpt4 book ai didi

hadoop - SubQuery 在 IMPALA 中有效,但在 HIVE 中无效

转载 作者:可可西里 更新时间:2023-11-01 15:45:54 25 4
gpt4 key购买 nike

我试图理解为什么以下子查询将在 Impala 而不是 Hive 中工作。

    select * from MySchema.MyTable where identifier not in 
(select identifier from schema.table where status_code in (1,2,3));

编辑:

添加了错误

Error while compiling statement: FAILED: SemanticException [Error 10249]: line 1:55 Unsupported SubQuery Expression 'identifier': Correlating expression cannot contain unqualified column references.

最佳答案

问题可能是因为两个查询中的“标识符”,在主查询和内部子查询中。明确提及您指的是哪个“标识符”(如“mytable.identifier”)应该可以解决此问题。

这可能是 Hive 的一个问题,已在最新版本中修复,并且该问题未在 Hive 3.1.0 中重现。

如果问题仍然存在,请告诉我们您使用的 Hive 版本和用于创建表的 DDL 语句。

关于hadoop - SubQuery 在 IMPALA 中有效,但在 HIVE 中无效,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54932537/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com