--source include/have_innodb.inc
|
|
CREATE TABLE t1 (id INT, a INT, PRIMARY KEY(id), KEY(a)) ENGINE=InnoDB;
|
INSERT INTO t1 VALUES (1,10),(2,20);
|
|
CREATE TABLE t2 (b CHAR(8)) ENGINE=InnoDB;
|
INSERT INTO t2 VALUES ('10'),('11');
|
|
SELECT MAX(id), a FROM (SELECT * FROM t1 WHERE a <> 4) AS sq WHERE a IN (SELECT MIN(b) FROM t2) GROUP BY a;
|
|
# Cleanup
|
DROP TABLE t1, t2;
|
10.2 6ede84f4
|
#3 <signal handler called>
|
#4 Item_ref::field_type (this=0x7f34f409cc10) at /data/src/10.2/sql/item.h:4492
|
#5 0x00005645a154ddfd in check_group_min_max_predicates (cond=0x7f34f409cc10, min_max_arg_item=0x7f34f4016d30, image_type=Field::itRAW, has_min_max_arg=0x7f35413a5c84, has_other_arg=0x7f35413a5c85) at /data/src/10.2/sql/opt_range.cc:13058
|
#6 0x00005645a154dace in check_group_min_max_predicates (cond=0x7f34f4098fa8, min_max_arg_item=0x7f34f4016d30, image_type=Field::itRAW, has_min_max_arg=0x7f35413a5dd8, has_other_arg=0x7f35413a5f30) at /data/src/10.2/sql/opt_range.cc:12996
|
#7 0x00005645a154d64e in get_best_group_min_max (param=0x7f35413a79c0, tree=0x7f34f40755e0, read_time=1.7976931348623157e+308) at /data/src/10.2/sql/opt_range.cc:12895
|
#8 0x00005645a1534f91 in SQL_SELECT::test_quick_select (this=0x7f34f409b058, thd=0x7f34f4000d90, keys_to_use=..., prev_tables=0, limit=18446744073709551615, force_quick_range=true, ordered_output=false, remove_false_parts_of_where=false) at /data/src/10.2/sql/opt_range.cc:2567
|
#9 0x00005645a11d8459 in test_if_skip_sort_order (tab=0x7f34f409a4c8, order=0x7f34f4016060, select_limit=2, no_changes=false, map=0x7f34f409d5b0) at /data/src/10.2/sql/sql_select.cc:21752
|
#10 0x00005645a11a5080 in JOIN::optimize_inner (this=0x7f34f40161a0) at /data/src/10.2/sql/sql_select.cc:2183
|
#11 0x00005645a11a146a in JOIN::optimize (this=0x7f34f40161a0) at /data/src/10.2/sql/sql_select.cc:1118
|
#12 0x00005645a11aa9a8 in mysql_select (thd=0x7f34f4000d90, tables=0x7f34f40141c8, wild_num=0, fields=..., conds=0x7f34f4015d18, og_num=1, order=0x0, group=0x7f34f4016060, having=0x0, proc_param=0x0, select_options=2147748608, result=0x7f34f4016180, unit=0x7f34f4004988, select_lex=0x7f34f40050c8) at /data/src/10.2/sql/sql_select.cc:3823
|
#13 0x00005645a119ebb2 in handle_select (thd=0x7f34f4000d90, lex=0x7f34f40048c8, result=0x7f34f4016180, setup_tables_done_option=0) at /data/src/10.2/sql/sql_select.cc:361
|
#14 0x00005645a11692bc in execute_sqlcom_select (thd=0x7f34f4000d90, all_tables=0x7f34f40141c8) at /data/src/10.2/sql/sql_parse.cc:6248
|
#15 0x00005645a115fc6b in mysql_execute_command (thd=0x7f34f4000d90) at /data/src/10.2/sql/sql_parse.cc:3559
|
#16 0x00005645a116d065 in mysql_parse (thd=0x7f34f4000d90, rawbuf=0x7f34f40126f8 "SELECT MAX(id), a FROM (SELECT * FROM t1 WHERE a <> 4) AS sq WHERE a IN (SELECT MIN(b) FROM t2) GROUP BY a", length=106, parser_state=0x7f35413a95f0, is_com_multi=false, is_next_command=false) at /data/src/10.2/sql/sql_parse.cc:7763
|
#17 0x00005645a115b33e in dispatch_command (command=COM_QUERY, thd=0x7f34f4000d90, packet=0x7f34f4008b51 "SELECT MAX(id), a FROM (SELECT * FROM t1 WHERE a <> 4) AS sq WHERE a IN (SELECT MIN(b) FROM t2) GROUP BY a", packet_length=106, is_com_multi=false, is_next_command=false) at /data/src/10.2/sql/sql_parse.cc:1827
|
#18 0x00005645a1159e39 in do_command (thd=0x7f34f4000d90) at /data/src/10.2/sql/sql_parse.cc:1381
|
#19 0x00005645a12b488e in do_handle_one_connection (connect=0x5645a35b33b0) at /data/src/10.2/sql/sql_connect.cc:1336
|
#20 0x00005645a12b45f3 in handle_one_connection (arg=0x5645a35b33b0) at /data/src/10.2/sql/sql_connect.cc:1241
|
#21 0x00005645a1adcb82 in pfs_spawn_thread (arg=0x5645a3509580) at /data/src/10.2/storage/perfschema/pfs.cc:1869
|
#22 0x00007f3547452609 in start_thread (arg=<optimized out>) at pthread_create.c:477
|
#23 0x00007f354702e293 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
|
Reproducible on 10.1-10.5, debug-, release- and ASAN builds alike.
Not reproducible with MyISAM or Aria.
{"report":{"fcp":850.8000000119209,"ttfb":166.80000001192093,"pageVisibility":"visible","entityId":96634,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":1,"journeyId":"1c47030a-f1a5-4ae0-b284-a44eb2fcdb4c","navigationType":0,"readyForUser":960.9000000357628,"redirectCount":0,"resourceLoadedEnd":951.5,"resourceLoadedStart":172.80000001192093,"resourceTiming":[{"duration":226,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":172.80000001192093,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":172.80000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":398.80000001192093,"responseStart":0,"secureConnectionStart":0},{"duration":226,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/download/contextbatch/css/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true","startTime":173.10000002384186,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":173.10000002384186,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":399.10000002384186,"responseStart":0,"secureConnectionStart":0},{"duration":234.69999998807907,"initiatorType":"script","name":"https://jira.mariadb.org/s/fbf975c0cce4b1abf04784eeae9ba1f4-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":173.30000001192093,"connectEnd":173.30000001192093,"connectStart":173.30000001192093,"domainLookupEnd":173.30000001192093,"domainLookupStart":173.30000001192093,"fetchStart":173.30000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":173.30000001192093,"responseEnd":408,"responseStart":408,"secureConnectionStart":173.30000001192093},{"duration":287.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/099b33461394b8015fc36c0a4b96e19f-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/download/contextbatch/js/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true","startTime":173.4000000357628,"connectEnd":173.4000000357628,"connectStart":173.4000000357628,"domainLookupEnd":173.4000000357628,"domainLookupStart":173.4000000357628,"fetchStart":173.4000000357628,"redirectEnd":0,"redirectStart":0,"requestStart":173.4000000357628,"responseEnd":460.9000000357628,"responseStart":460.9000000357628,"secureConnectionStart":173.4000000357628},{"duration":291,"initiatorType":"script","name":"https://jira.mariadb.org/s/94c15bff32baef80f4096a08aceae8bc-CDN/lu2bu7/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":173.60000002384186,"connectEnd":173.60000002384186,"connectStart":173.60000002384186,"domainLookupEnd":173.60000002384186,"domainLookupStart":173.60000002384186,"fetchStart":173.60000002384186,"redirectEnd":0,"redirectStart":0,"requestStart":173.60000002384186,"responseEnd":464.60000002384186,"responseStart":464.60000002384186,"secureConnectionStart":173.60000002384186},{"duration":291.30000001192093,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":173.80000001192093,"connectEnd":173.80000001192093,"connectStart":173.80000001192093,"domainLookupEnd":173.80000001192093,"domainLookupStart":173.80000001192093,"fetchStart":173.80000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":173.80000001192093,"responseEnd":465.10000002384186,"responseStart":465.10000002384186,"secureConnectionStart":173.80000001192093},{"duration":291.4000000357628,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":174,"connectEnd":174,"connectStart":174,"domainLookupEnd":174,"domainLookupStart":174,"fetchStart":174,"redirectEnd":0,"redirectStart":0,"requestStart":174,"responseEnd":465.4000000357628,"responseStart":465.4000000357628,"secureConnectionStart":174},{"duration":374.5,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2bu7/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":174.19999998807907,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":174.19999998807907,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":548.6999999880791,"responseStart":0,"secureConnectionStart":0},{"duration":291.60000002384186,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":174.30000001192093,"connectEnd":174.30000001192093,"connectStart":174.30000001192093,"domainLookupEnd":174.30000001192093,"domainLookupStart":174.30000001192093,"fetchStart":174.30000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":174.30000001192093,"responseEnd":465.9000000357628,"responseStart":465.9000000357628,"secureConnectionStart":174.30000001192093},{"duration":374.5,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2bu7/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/css/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.css?jira.create.linked.issue=true","startTime":174.4000000357628,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":174.4000000357628,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":548.9000000357628,"responseStart":0,"secureConnectionStart":0},{"duration":291.89999997615814,"initiatorType":"script","name":"https://jira.mariadb.org/s/3339d87fa2538a859872f2df449bf8d0-CDN/lu2bu7/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/js/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.js?jira.create.linked.issue=true&locale=en","startTime":174.60000002384186,"connectEnd":174.60000002384186,"connectStart":174.60000002384186,"domainLookupEnd":174.60000002384186,"domainLookupStart":174.60000002384186,"fetchStart":174.60000002384186,"redirectEnd":0,"redirectStart":0,"requestStart":174.60000002384186,"responseEnd":466.5,"responseStart":466.5,"secureConnectionStart":174.60000002384186},{"duration":408.7999999523163,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":175.4000000357628,"connectEnd":175.4000000357628,"connectStart":175.4000000357628,"domainLookupEnd":175.4000000357628,"domainLookupStart":175.4000000357628,"fetchStart":175.4000000357628,"redirectEnd":0,"redirectStart":0,"requestStart":175.4000000357628,"responseEnd":584.1999999880791,"responseStart":584.1999999880791,"secureConnectionStart":175.4000000357628},{"duration":508.60000002384186,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":175.5,"connectEnd":175.5,"connectStart":175.5,"domainLookupEnd":175.5,"domainLookupStart":175.5,"fetchStart":175.5,"redirectEnd":0,"redirectStart":0,"requestStart":175.5,"responseEnd":684.1000000238419,"responseStart":684.1000000238419,"secureConnectionStart":175.5},{"duration":49.5,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":560,"connectEnd":560,"connectStart":560,"domainLookupEnd":560,"domainLookupStart":560,"fetchStart":560,"redirectEnd":0,"redirectStart":0,"requestStart":560,"responseEnd":609.5,"responseStart":609.5,"secureConnectionStart":560},{"duration":197.60000002384186,"initiatorType":"link","name":"https://jira.mariadb.org/s/d5715adaadd168a9002b108b2b039b50-CDN/lu2bu7/820016/12ta74/be4b45e9cec53099498fa61c8b7acba4/_/download/contextbatch/css/jira.project.sidebar,-_super,-project.issue.navigator,-jira.general,-jira.browse.project,-jira.view.issue,-jira.global,-atl.general,-com.atlassian.jira.projects.sidebar.init/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true","startTime":612.6999999880791,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":612.6999999880791,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":810.3000000119209,"responseStart":0,"secureConnectionStart":0},{"duration":335.39999997615814,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/e65b778d185daf5aee24936755b43da6/_/download/contextbatch/js/browser-metrics-plugin.contrib,-_super,-project.issue.navigator,-jira.view.issue,-atl.general/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true","startTime":613.6000000238419,"connectEnd":613.6000000238419,"connectStart":613.6000000238419,"domainLookupEnd":613.6000000238419,"domainLookupStart":613.6000000238419,"fetchStart":613.6000000238419,"redirectEnd":0,"redirectStart":0,"requestStart":613.6000000238419,"responseEnd":949,"responseStart":949,"secureConnectionStart":613.6000000238419},{"duration":337.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/f51ef5507eea4c158f257c66c93b2a3f-CDN/lu2bu7/820016/12ta74/be4b45e9cec53099498fa61c8b7acba4/_/download/contextbatch/js/jira.project.sidebar,-_super,-project.issue.navigator,-jira.general,-jira.browse.project,-jira.view.issue,-jira.global,-atl.general,-com.atlassian.jira.projects.sidebar.init/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true","startTime":614,"connectEnd":614,"connectStart":614,"domainLookupEnd":614,"domainLookupStart":614,"fetchStart":614,"redirectEnd":0,"redirectStart":0,"requestStart":614,"responseEnd":951.5,"responseStart":951.5,"secureConnectionStart":614},{"duration":165.30000001192093,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":844,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":844,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1009.3000000119209,"responseStart":0,"secureConnectionStart":0},{"duration":146.10000002384186,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":851.1999999880791,"connectEnd":851.1999999880791,"connectStart":851.1999999880791,"domainLookupEnd":851.1999999880791,"domainLookupStart":851.1999999880791,"fetchStart":851.1999999880791,"redirectEnd":0,"redirectStart":0,"requestStart":851.1999999880791,"responseEnd":997.3000000119209,"responseStart":997.3000000119209,"secureConnectionStart":851.1999999880791}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":15,"responseStart":167,"responseEnd":169,"domLoading":171,"domInteractive":1025,"domContentLoadedEventStart":1025,"domContentLoadedEventEnd":1070,"domComplete":1522,"loadEventStart":1522,"loadEventEnd":1523,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":997.1000000238419},{"name":"bigPipe.sidebar-id.end","time":997.9000000357628},{"name":"bigPipe.activity-panel-pipe-id.start","time":998},{"name":"bigPipe.activity-panel-pipe-id.end","time":1000.3000000119209},{"name":"activityTabFullyLoaded","time":1080.1000000238419}],"measures":[],"correlationId":"3fb6b8caa97678","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":90,"dbReadsTimeInMs":9,"dbConnsTimeInMs":16,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}