You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2020/09/18 00:26:00 UTC
[jira] [Commented] (IMPALA-10157) IllegalStateException when using
grouping() or grouping_id() with no GROUP BY clause
[ https://issues.apache.org/jira/browse/IMPALA-10157?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17198033#comment-17198033 ]
ASF subversion and git services commented on IMPALA-10157:
----------------------------------------------------------
Commit b800f4a9234f2005e47e056ce3d164720c20bed8 in impala's branch refs/heads/master from Tim Armstrong
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=b800f4a ]
IMPALA-10157: analysis error for grouping_id() w/o group by
The following query is invalid because it uses grouping() without a
group by clause.
select int_col, grouping(int_col)
from functional.alltypes
Instead of an IllegalStateException, catch these invalid
queries in analysis and throw an AnalysisException with
a better message.
Change-Id: I1dae36e32a465b3f25ba32a4468cb386d53b7c8a
Reviewed-on: http://gerrit.cloudera.org:8080/16431
Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
> IllegalStateException when using grouping() or grouping_id() with no GROUP BY clause
> ------------------------------------------------------------------------------------
>
> Key: IMPALA-10157
> URL: https://issues.apache.org/jira/browse/IMPALA-10157
> Project: IMPALA
> Issue Type: Bug
> Components: Frontend
> Reporter: Tim Armstrong
> Assignee: Tim Armstrong
> Priority: Major
>
> {noformat}https://issues.apache.org/jira/browse/IMPALA-10157#
> [localhost.EXAMPLE.COM:21000] default> select int_col, tinyint_col, grouping(int_col), grouping(tinyint_col), grouping_id(int_col, tinyint_col) from functional.alltypes;
> Query: select int_col, tinyint_col, grouping(int_col), grouping(tinyint_col), grouping_id(int_col, tinyint_col) from functional.alltypes
> Query submitted at: 2020-09-08 10:25:12 (Coordinator: http://tarmstrong-box2:25000)
> ERROR: IllegalStateException: null
> {noformat}
> {noformat}
> I0908 10:25:12.834306 19139 Frontend.java:1507] a845d2d57577cc5c:b905608c00000000] Analyzing query: select int_col, tinyint_col, grouping(int_col), grouping(tinyint_col), grouping_id(int_col, tinyint_col) from functional.alltypes db: default
> I0908 10:25:12.839713 19139 jni-util.cc:288] a845d2d57577cc5c:b905608c00000000] java.lang.IllegalStateException
> at com.google.common.base.Preconditions.checkState(Preconditions.java:492)
> at org.apache.impala.analysis.MultiAggregateInfo.analyze(MultiAggregateInfo.java:274)
> at org.apache.impala.analysis.SelectStmt$SelectAnalyzer.buildAggregateExprs(SelectStmt.java:845)
> at org.apache.impala.analysis.SelectStmt$SelectAnalyzer.analyze(SelectStmt.java:269)
> at org.apache.impala.analysis.SelectStmt$SelectAnalyzer.access$100(SelectStmt.java:237)
> at org.apache.impala.analysis.SelectStmt.analyze(SelectStmt.java:230)
> at org.apache.impala.analysis.AnalysisContext.analyze(AnalysisContext.java:472)
> at org.apache.impala.analysis.AnalysisContext.analyzeAndAuthorize(AnalysisContext.java:436)
> at org.apache.impala.service.Frontend.doCreateExecRequest(Frontend.java:1547)
> at org.apache.impala.service.Frontend.getTExecRequest(Frontend.java:1514)
> at org.apache.impala.service.Frontend.createExecRequest(Frontend.java:1484)
> at org.apache.impala.service.JniFrontend.createExecRequest(JniFrontend.java:162)
> I0908 10:25:12.839778 19139 status.cc:129] a845d2d57577cc5c:b905608c00000000] IllegalStateException: null
> @ 0x1ce443b impala::Status::Status()
> @ 0x2644a01 impala::JniUtil::GetJniExceptionMsg()
> @ 0x2446c96 impala::JniCall::Call<>()
> @ 0x2443e49 impala::JniUtil::CallJniMethod<>()
> @ 0x2442150 impala::Frontend::GetExecRequest()
> @ 0x2cc4d47 impala::QueryDriver::RunFrontendPlanner()
> @ 0x246f844 impala::ImpalaServer::ExecuteInternal()
> @ 0x246f202 impala::ImpalaServer::Execute()
> @ 0x25098c6 impala::ImpalaServer::query()
> @ 0x2afb7df beeswax::BeeswaxServiceProcessor::process_query()
> @ 0x2afb52d beeswax::BeeswaxServiceProcessor::dispatchCall()
> @ 0x2ac8976 impala::ImpalaServiceProcessor::dispatchCall()
> @ 0x1c92db3 apache::thrift::TDispatchProcessor::process()
> @ 0x2195f36 apache::thrift::server::TAcceptQueueServer::Task::run()
> @ 0x218b436 impala::ThriftThread::RunRunnable()
> @ 0x218ca72 boost::_mfi::mf2<>::operator()()
> @ 0x218c906 boost::_bi::list3<>::operator()<>()
> @ 0x218c64c boost::_bi::bind_t<>::operator()()
> @ 0x218c55e boost::detail::function::void_function_obj_invoker0<>::invoke()
> @ 0x2107043 boost::function0<>::operator()()
> @ 0x26d5ea5 impala::Thread::SuperviseThread()
> @ 0x26dde42 boost::_bi::list5<>::operator()<>()
> @ 0x26ddd66 boost::_bi::bind_t<>::operator()()
> @ 0x26ddd27 boost::detail::thread_data<>::run()
> @ 0x3ec7271 thread_proxy
> @ 0x7fa5b50b76da start_thread
> @ 0x7fa5b1aaea3e clone
> {noformat}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org