This crash is very similar to MDEV-18156, but now with TIME_ROUND_FRACTIONAL instead of PAD_CHAR_TO_FULL_LENGTH.
It should be addressed in a separate patch after the fix for MDEV-18156 propagates to 10.4.
This crash is also very similar to MDEV-18153, but the generation expressions are different:
- GENERATED ALWAYS AS (CAST(a AS DATETIME(3))) VIRTUAL
- GENERATED ALWAYS AS (CAST(a AS TIME(3))) VIRTUAL
MDEV-18156 needs MDEV-18156 as a dependency. MDEV-18153 can possibly be fixed alone.
SET sql_mode='';
|
CREATE OR REPLACE TABLE t1 (
|
a DATETIME(6),
|
v VARCHAR(30) GENERATED ALWAYS AS (CAST(a AS DATETIME(3))) VIRTUAL,
|
KEY (v)
|
);
|
INSERT IGNORE INTO t1 (a) VALUES ('2001-01-01 10:20:30.999999');
|
SELECT * FROM t1;
|
SET sql_mode=TIME_ROUND_FRACTIONAL;
|
FLUSH TABLES;
|
SELECT * FROM t1;
|
UPDATE t1 SET a='2001-01-02 10:20:30.999999';
|
#0 0x00007ffff76f357f in raise () from /lib64/libc.so.6
|
#1 0x00007ffff76dd895 in abort () from /lib64/libc.so.6
|
#2 0x00007ffff76dd769 in __assert_fail_base.cold.0 () from /lib64/libc.so.6
|
#3 0x00007ffff76eba26 in __assert_fail () from /lib64/libc.so.6
|
#4 0x0000000000eff9ac in row_upd_sec_index_entry (node=0x7fff60083cd0, thr=0x7fff60083fd8)
|
at /home/bar/maria-git/server.10.4/storage/innobase/row/row0upd.cc:2429
|
#5 0x0000000000f0001e in row_upd_sec_step (node=0x7fff60083cd0, thr=0x7fff60083fd8)
|
at /home/bar/maria-git/server.10.4/storage/innobase/row/row0upd.cc:2543
|
#6 0x0000000000f02736 in row_upd (node=0x7fff60083cd0, thr=0x7fff60083fd8)
|
at /home/bar/maria-git/server.10.4/storage/innobase/row/row0upd.cc:3319
|
#7 0x0000000000f02a9d in row_upd_step (thr=0x7fff60083fd8)
|
at /home/bar/maria-git/server.10.4/storage/innobase/row/row0upd.cc:3434
|
#8 0x0000000000eb654c in row_update_for_mysql (prebuilt=0x7fff60083518)
|
at /home/bar/maria-git/server.10.4/storage/innobase/row/row0mysql.cc:1889
|
#9 0x0000000000d60723 in ha_innobase::update_row (this=0x7fff6001dcf8,
|
old_row=0x7fff6001d8a0 "\374\231g\202\245\036\017B?\027\062\060\060\061-01-01 10:20:31.000",
|
new_row=0x7fff6001d870 "\374\231g\204\245\036\017B?\027\062\060\060\061-01-02 10:20:31.000")
|
at /home/bar/maria-git/server.10.4/storage/innobase/handler/ha_innodb.cc:8840
|
#10 0x0000000000b4bc0a in handler::ha_update_row (this=0x7fff6001dcf8,
|
old_data=0x7fff6001d8a0 "\374\231g\202\245\036\017B?\027\062\060\060\061-01-01 10:20:31.000",
|
new_data=0x7fff6001d870 "\374\231g\204\245\036\017B?\027\062\060\060\061-01-02 10:20:31.000")
|
at /home/bar/maria-git/server.10.4/sql/handler.cc:6727
|
#11 0x000000000091b9ad in mysql_update (thd=0x7fff60000d60, table_list=0x7fff60014270, fields=...,
|
values=..., conds=0x0, order_num=0, order=0x0, limit=18446744073709551615, ignore=false,
|
found_return=0x7ffff41d6218, updated_return=0x7ffff41d6210)
|
at /home/bar/maria-git/server.10.4/sql/sql_update.cc:1045
|
#12 0x0000000000820bc2 in mysql_execute_command (thd=0x7fff60000d60)
|
at /home/bar/maria-git/server.10.4/sql/sql_parse.cc:4369
|
#13 0x000000000082cd07 in mysql_parse (thd=0x7fff60000d60,
|
rawbuf=0x7fff60014168 "UPDATE t1 SET a='2001-01-02 10:20:30.999999'", length=44,
|
parser_state=0x7ffff41d7000, is_com_multi=false, is_next_command=false)
|
at /home/bar/maria-git/server.10.4/sql/sql_parse.cc:7908
|
#14 0x000000000081981c in dispatch_command (command=COM_QUERY, thd=0x7fff60000d60,
|
packet=0x7fff600085e1 "UPDATE t1 SET a='2001-01-02 10:20:30.999999'", packet_length=44,
|
is_com_multi=false, is_next_command=false) at /home/bar/maria-git/server.10.4/sql/sql_parse.cc:1842
|
#15 0x0000000000817fc6 in do_command (thd=0x7fff60000d60)
|
The same problem is repeatable with TIME type cast:
SET sql_mode='';
|
CREATE OR REPLACE TABLE t1 (
|
a TIME(6),
|
v VARCHAR(30) GENERATED ALWAYS AS (CAST(a AS TIME(3))) VIRTUAL,
|
KEY (v)
|
);
|
INSERT IGNORE INTO t1 (a) VALUES ('10:20:30.999999');
|
SELECT * FROM t1;
|
SET sql_mode=TIME_ROUND_FRACTIONAL;
|
FLUSH TABLES;
|
SELECT * FROM t1;
|
UPDATE t1 SET a='11:20:30.999999';
|
{"report":{"fcp":688.0999999046326,"ttfb":202.20000004768372,"pageVisibility":"visible","entityId":78512,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":1,"journeyId":"10c3970f-f984-4e78-b673-1c09e0884a25","navigationType":0,"readyForUser":835.0999999046326,"redirectCount":0,"resourceLoadedEnd":717.2000000476837,"resourceLoadedStart":208.20000004768372,"resourceTiming":[{"duration":7,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":208.20000004768372,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":208.20000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":215.20000004768372,"responseStart":0,"secureConnectionStart":0},{"duration":6.799999952316284,"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":208.70000004768372,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":208.70000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":215.5,"responseStart":0,"secureConnectionStart":0},{"duration":63.39999985694885,"initiatorType":"script","name":"https://jira.mariadb.org/s/fbf975c0cce4b1abf04784eeae9ba1f4-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":208.90000009536743,"connectEnd":208.90000009536743,"connectStart":208.90000009536743,"domainLookupEnd":208.90000009536743,"domainLookupStart":208.90000009536743,"fetchStart":208.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":208.90000009536743,"responseEnd":272.2999999523163,"responseStart":272.2999999523163,"secureConnectionStart":208.90000009536743},{"duration":170.59999990463257,"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":209,"connectEnd":209,"connectStart":209,"domainLookupEnd":209,"domainLookupStart":209,"fetchStart":209,"redirectEnd":0,"redirectStart":0,"requestStart":209,"responseEnd":379.59999990463257,"responseStart":379.59999990463257,"secureConnectionStart":209},{"duration":174.20000004768372,"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":209.20000004768372,"connectEnd":209.20000004768372,"connectStart":209.20000004768372,"domainLookupEnd":209.20000004768372,"domainLookupStart":209.20000004768372,"fetchStart":209.20000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":209.20000004768372,"responseEnd":383.40000009536743,"responseStart":383.40000009536743,"secureConnectionStart":209.20000004768372},{"duration":174.70000004768372,"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":209.29999995231628,"connectEnd":209.29999995231628,"connectStart":209.29999995231628,"domainLookupEnd":209.29999995231628,"domainLookupStart":209.29999995231628,"fetchStart":209.29999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":209.29999995231628,"responseEnd":384,"responseStart":384,"secureConnectionStart":209.29999995231628},{"duration":175.09999990463257,"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":209.40000009536743,"connectEnd":209.40000009536743,"connectStart":209.40000009536743,"domainLookupEnd":209.40000009536743,"domainLookupStart":209.40000009536743,"fetchStart":209.40000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":209.40000009536743,"responseEnd":384.5,"responseStart":384.5,"secureConnectionStart":209.40000009536743},{"duration":175.70000004768372,"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":209.5,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":209.5,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":385.2000000476837,"responseStart":0,"secureConnectionStart":0},{"duration":175.60000014305115,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":209.59999990463257,"connectEnd":209.59999990463257,"connectStart":209.59999990463257,"domainLookupEnd":209.59999990463257,"domainLookupStart":209.59999990463257,"fetchStart":209.59999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":209.59999990463257,"responseEnd":385.2000000476837,"responseStart":385.2000000476837,"secureConnectionStart":209.59999990463257},{"duration":176.09999990463257,"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":209.70000004768372,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":209.70000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":385.7999999523163,"responseStart":0,"secureConnectionStart":0},{"duration":176.20000004768372,"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":209.79999995231628,"connectEnd":209.79999995231628,"connectStart":209.79999995231628,"domainLookupEnd":209.79999995231628,"domainLookupStart":209.79999995231628,"fetchStart":209.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":209.79999995231628,"responseEnd":386,"responseStart":386,"secureConnectionStart":209.79999995231628},{"duration":460,"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":210.79999995231628,"connectEnd":210.79999995231628,"connectStart":210.79999995231628,"domainLookupEnd":210.79999995231628,"domainLookupStart":210.79999995231628,"fetchStart":210.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":210.79999995231628,"responseEnd":670.7999999523163,"responseStart":670.7999999523163,"secureConnectionStart":210.79999995231628},{"duration":467.90000009536743,"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":215.29999995231628,"connectEnd":215.29999995231628,"connectStart":215.29999995231628,"domainLookupEnd":215.29999995231628,"domainLookupStart":215.29999995231628,"fetchStart":215.29999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":215.29999995231628,"responseEnd":683.2000000476837,"responseStart":683.2000000476837,"secureConnectionStart":215.29999995231628},{"duration":245.29999995231628,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":425.90000009536743,"connectEnd":425.90000009536743,"connectStart":425.90000009536743,"domainLookupEnd":425.90000009536743,"domainLookupStart":425.90000009536743,"fetchStart":425.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":425.90000009536743,"responseEnd":671.2000000476837,"responseStart":671.2000000476837,"secureConnectionStart":425.90000009536743},{"duration":7.700000047683716,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":681.2000000476837,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":681.2000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":688.9000000953674,"responseStart":0,"secureConnectionStart":0},{"duration":3.0999999046325684,"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":705.2000000476837,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":705.2000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":708.2999999523163,"responseStart":0,"secureConnectionStart":0},{"duration":4.1000001430511475,"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":706.0999999046326,"connectEnd":706.0999999046326,"connectStart":706.0999999046326,"domainLookupEnd":706.0999999046326,"domainLookupStart":706.0999999046326,"fetchStart":706.0999999046326,"redirectEnd":0,"redirectStart":0,"requestStart":706.0999999046326,"responseEnd":710.2000000476837,"responseStart":710.2000000476837,"secureConnectionStart":706.0999999046326},{"duration":10.799999952316284,"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":706.4000000953674,"connectEnd":706.4000000953674,"connectStart":706.4000000953674,"domainLookupEnd":706.4000000953674,"domainLookupStart":706.4000000953674,"fetchStart":706.4000000953674,"redirectEnd":0,"redirectStart":0,"requestStart":706.4000000953674,"responseEnd":717.2000000476837,"responseStart":717.0999999046326,"secureConnectionStart":706.4000000953674}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":65,"responseStart":203,"responseEnd":208,"domLoading":206,"domInteractive":914,"domContentLoadedEventStart":914,"domContentLoadedEventEnd":970,"domComplete":1591,"loadEventStart":1591,"loadEventEnd":1593,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":884.5},{"name":"bigPipe.sidebar-id.end","time":885.2999999523163},{"name":"bigPipe.activity-panel-pipe-id.start","time":885.4000000953674},{"name":"bigPipe.activity-panel-pipe-id.end","time":887.9000000953674},{"name":"activityTabFullyLoaded","time":978.5}],"measures":[],"correlationId":"14b200cd5cbd2b","effectiveType":"4g","downlink":9.2,"rtt":0,"serverDuration":75,"dbReadsTimeInMs":13,"dbConnsTimeInMs":20,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}