EmmyMiao87 opened a new issue #7929: URL: https://github.com/apache/incubator-doris/issues/7929
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/incubator-doris/issues?q=is%3Aissue) and found no similar issues. ### Version All versions before this pr fix ### What's Wrong? *** Aborted at 1643354333 (unix time) try "date -d @1643354333" if you are using GNU date *** PC: @ 0x146f036 doris::RowDescriptor::tuple_is_nullable() *** SIGSEGV (@0x0) received by PID 22713 (TID 0x7fe56fcf1700) from PID 0; stack trace: *** @ 0x209e942 google::(anonymous namespace)::FailureSignalHandler() @ 0x7fe6045d1630 (unknown) @ 0x146f036 doris::RowDescriptor::tuple_is_nullable() @ 0x1212d77 doris::TupleIsNullPredicate::prepare() @ 0x11da1c2 doris::Expr::prepare() @ 0x11e4820 doris::ExprContext::prepare() @ 0x11db0ae doris::Expr::prepare() @ 0x1bc3e13 doris::ResultSink::prepare_exprs() @ 0x1bc45b8 doris::ResultSink::prepare() @ 0x152fc7b doris::PlanFragmentExecutor::prepare() @ 0x14a851e doris::FragmentExecState::prepare() @ 0x14ac4ea doris::FragmentMgr::exec_plan_fragment() @ 0x14ae182 doris::FragmentMgr::exec_plan_fragment() @ 0x1575954 doris::PInternalServiceImpl<>::_exec_plan_fragment() @ 0x1575a0f doris::PInternalServiceImpl<>::exec_plan_fragment() @ 0x22115a7 brpc::policy::ProcessHttpRequest() @ 0x21de9c7 brpc::ProcessInputMessage() @ 0x21df88e brpc::InputMessenger::OnNewMessages() @ 0x2287dee brpc::Socket::ProcessEvent() @ 0x23305cf bthread::TaskGroup::task_runner() @ 0x23219d1 bthread_make_fcontext ### What You Expected? Return 0 rows ### How to Reproduce? step1: ``` CREATE TABLE `t1` ( `k1` int(11) NULL COMMENT "", `k2` int(11) NULL COMMENT "" ) ENGINE=OLAP DUPLICATE KEY(`k1`, `k2`) COMMENT "OLAP" DISTRIBUTED BY HASH(`k1`) BUCKETS 1 PROPERTIES ( "replication_allocation" = "tag.location.default: 3", "in_memory" = "false", "storage_format" = "V2" ) ``` step2: ``` CREATE TABLE `t2` ( `j1` int(11) NULL COMMENT "", `j2` int(11) NULL COMMENT "" ) ENGINE=OLAP DUPLICATE KEY(`j1`, `j2`) COMMENT "OLAP" DISTRIBUTED BY HASH(`j1`) BUCKETS 1 PROPERTIES ( "replication_allocation" = "tag.location.default: 3", "in_memory" = "false", "storage_format" = "V2" ) ``` step3: query and be core sometimes ``` select * from t1 left join (select max(j1) over() as x from t2)a on t1.k1=a.x where 1=1; ``` ### Anything Else? The explain of query as following: ``` MySQL [bpit]> desc verbose select * from t1 left join (select max(j1) over() as x from t2)a on t1.k1=a.x where 1=0; +--------------------------------------------------------------------------------------------------------------------------+ | Explain String | +--------------------------------------------------------------------------------------------------------------------------+ | PLAN FRAGMENT 0 | | OUTPUT EXPRS:`default_cluster:bpit`.`t1`.`k1` | `default_cluster:bpit`.`t1`.`k2` | if(TupleIsNull(1,5), NULL, <slot 6>) | | PARTITION: UNPARTITIONED | | | | RESULT SINK | | | | 4:EMPTYSET | | tuple ids: 0 1 | | | ``` The empty set tuple ids is wrong: 0, 1 The right result is: 0, 1, 5 The tuple 5 is belongs to analytic function. ### Are you willing to submit PR? - [X] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org