"LOAD DATA INFILE" fails, for binary (or, geometry) data , for the file created with SELECT * INTO OUTFILE
I'm attaching example data where it can be demonstrated.
To reproduce, extract the dump file and load it
mariadb -uroot test < /mnt/e/airport_geo.mysqldump.sql
|
mariadb -uroot test -e "SELECT * FROM airport_geo INTO OUTFILE '/mnt/e/airport_geo.tsv'"
|
mariadb -uroot test -e "TRUNCATE airport_geo; LOAD DATA INFILE '/mnt/e/airport_geo.tsv' INTO TABLE airport_geo"
|
The last command fails with
--------------
|
LOAD DATA INFILE '/mnt/e/airport_geo.tsv' INTO TABLE airport_geo
|
--------------
|
|
ERROR 1263 (22004) at line 1: Column set to default value; NULL supplied to NOT NULL column 'geolocation' at row 42
|
this is the DDL for the create table, column "geolocation" is a POINT
CREATE TABLE `airport_geo` (
|
`airport_id` smallint(6) NOT NULL,
|
`name` varchar(50) NOT NULL,
|
`city` varchar(50) DEFAULT NULL,
|
`country` varchar(50) DEFAULT NULL,
|
`latitude` decimal(11,8) NOT NULL,
|
`longitude` decimal(11,8) NOT NULL,
|
`geolocation` point NOT NULL,
|
KEY `flughafen_idx` (`airport_id`),
|
SPATIAL KEY `geolokation_spt` (`geolocation`)
|
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
"git bisect" points to MDEV-19123 as first bad commit
36eba98817339f53cc57f1d4884ace3efb38db8d is the first bad commit
|
commit 36eba98817339f53cc57f1d4884ace3efb38db8d
|
Date: Tue May 28 09:08:51 2024 +0400
|
|
MDEV-19123 Change default charset from latin1 to utf8mb4
|
|
Changing the default server character set from latin1 to utf8mb4.
|
{"report":{"fcp":847.3999999761581,"ttfb":219.60000002384186,"pageVisibility":"visible","entityId":130647,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":1,"journeyId":"e165443f-d792-4790-8066-01a22c396f2e","navigationType":0,"readyForUser":944.5,"redirectCount":0,"resourceLoadedEnd":1282,"resourceLoadedStart":252.80000001192093,"resourceTiming":[{"duration":114.69999998807907,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2bv2/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":252.80000001192093,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":252.80000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":367.5,"responseStart":0,"secureConnectionStart":0},{"duration":114.69999998807907,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2bv2/820016/12ta74/2380add21a9a1006587582385952de73/_/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":253.19999998807907,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":253.19999998807907,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":367.89999997615814,"responseStart":0,"secureConnectionStart":0},{"duration":124,"initiatorType":"script","name":"https://jira.mariadb.org/s/e9b27a47da5fb0f74a35acd57e9847fb-CDN/lu2bv2/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":253.30000001192093,"connectEnd":253.30000001192093,"connectStart":253.30000001192093,"domainLookupEnd":253.30000001192093,"domainLookupStart":253.30000001192093,"fetchStart":253.30000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":253.30000001192093,"responseEnd":377.30000001192093,"responseStart":377.30000001192093,"secureConnectionStart":253.30000001192093},{"duration":177.60000002384186,"initiatorType":"script","name":"https://jira.mariadb.org/s/c32eb0da7ad9831253f8397e6cc26afd-CDN/lu2bv2/820016/12ta74/2380add21a9a1006587582385952de73/_/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":253.5,"connectEnd":253.5,"connectStart":253.5,"domainLookupEnd":253.5,"domainLookupStart":253.5,"fetchStart":253.5,"redirectEnd":0,"redirectStart":0,"requestStart":253.5,"responseEnd":431.10000002384186,"responseStart":431.10000002384186,"secureConnectionStart":253.5},{"duration":181,"initiatorType":"script","name":"https://jira.mariadb.org/s/bc0bcb146314416123c992714ee00ff7-CDN/lu2bv2/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":253.80000001192093,"connectEnd":253.80000001192093,"connectStart":253.80000001192093,"domainLookupEnd":253.80000001192093,"domainLookupStart":253.80000001192093,"fetchStart":253.80000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":253.80000001192093,"responseEnd":434.80000001192093,"responseStart":434.80000001192093,"secureConnectionStart":253.80000001192093},{"duration":181.30000001192093,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bv2/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":253.89999997615814,"connectEnd":253.89999997615814,"connectStart":253.89999997615814,"domainLookupEnd":253.89999997615814,"domainLookupStart":253.89999997615814,"fetchStart":253.89999997615814,"redirectEnd":0,"redirectStart":0,"requestStart":253.89999997615814,"responseEnd":435.19999998807907,"responseStart":435.19999998807907,"secureConnectionStart":253.89999997615814},{"duration":181.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bv2/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":254.19999998807907,"connectEnd":254.19999998807907,"connectStart":254.19999998807907,"domainLookupEnd":254.19999998807907,"domainLookupStart":254.19999998807907,"fetchStart":254.19999998807907,"redirectEnd":0,"redirectStart":0,"requestStart":254.19999998807907,"responseEnd":435.69999998807907,"responseStart":435.69999998807907,"secureConnectionStart":254.19999998807907},{"duration":265.0999999642372,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2bv2/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":254.30000001192093,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":254.30000001192093,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":519.3999999761581,"responseStart":0,"secureConnectionStart":0},{"duration":181.80000001192093,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":254.39999997615814,"connectEnd":254.39999997615814,"connectStart":254.39999997615814,"domainLookupEnd":254.39999997615814,"domainLookupStart":254.39999997615814,"fetchStart":254.39999997615814,"redirectEnd":0,"redirectStart":0,"requestStart":254.39999997615814,"responseEnd":436.19999998807907,"responseStart":436.19999998807907,"secureConnectionStart":254.39999997615814},{"duration":264.80000001192093,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2bv2/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":254.69999998807907,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":254.69999998807907,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":519.5,"responseStart":0,"secureConnectionStart":0},{"duration":181.80000001192093,"initiatorType":"script","name":"https://jira.mariadb.org/s/719848dd97ebe0663199f49a3936487a-CDN/lu2bv2/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":254.89999997615814,"connectEnd":254.89999997615814,"connectStart":254.89999997615814,"domainLookupEnd":254.89999997615814,"domainLookupStart":254.89999997615814,"fetchStart":254.89999997615814,"redirectEnd":0,"redirectStart":0,"requestStart":254.89999997615814,"responseEnd":436.69999998807907,"responseStart":436.69999998807907,"secureConnectionStart":254.89999997615814},{"duration":994.2999999523163,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bv2/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":256.10000002384186,"connectEnd":256.10000002384186,"connectStart":256.10000002384186,"domainLookupEnd":256.10000002384186,"domainLookupStart":256.10000002384186,"fetchStart":256.10000002384186,"redirectEnd":0,"redirectStart":0,"requestStart":256.10000002384186,"responseEnd":1250.3999999761581,"responseStart":1250.3999999761581,"secureConnectionStart":256.10000002384186},{"duration":995.2999999523163,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bv2/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":256.10000002384186,"connectEnd":256.10000002384186,"connectStart":256.10000002384186,"domainLookupEnd":256.10000002384186,"domainLookupStart":256.10000002384186,"fetchStart":256.10000002384186,"redirectEnd":0,"redirectStart":0,"requestStart":256.10000002384186,"responseEnd":1251.3999999761581,"responseStart":1251.3999999761581,"secureConnectionStart":256.10000002384186},{"duration":196.10000002384186,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":530.8999999761581,"connectEnd":530.8999999761581,"connectStart":530.8999999761581,"domainLookupEnd":530.8999999761581,"domainLookupStart":530.8999999761581,"fetchStart":530.8999999761581,"redirectEnd":0,"redirectStart":0,"requestStart":530.8999999761581,"responseEnd":727,"responseStart":727,"secureConnectionStart":530.8999999761581},{"duration":484.30000001192093,"initiatorType":"link","name":"https://jira.mariadb.org/s/d5715adaadd168a9002b108b2b039b50-CDN/lu2bv2/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":797.6999999880791,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":797.6999999880791,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1282,"responseStart":0,"secureConnectionStart":0},{"duration":570.1999999880791,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bv2/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":798.6999999880791,"connectEnd":798.6999999880791,"connectStart":798.6999999880791,"domainLookupEnd":798.6999999880791,"domainLookupStart":798.6999999880791,"fetchStart":798.6999999880791,"redirectEnd":0,"redirectStart":0,"requestStart":798.6999999880791,"responseEnd":1368.8999999761581,"responseStart":1368.8999999761581,"secureConnectionStart":798.6999999880791}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":18,"responseStart":219,"responseEnd":221,"domLoading":250,"domInteractive":1311,"domContentLoadedEventStart":1311,"domContentLoadedEventEnd":1358,"domComplete":1870,"loadEventStart":1870,"loadEventEnd":1871,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":1288.1000000238419},{"name":"bigPipe.sidebar-id.end","time":1288.800000011921},{"name":"bigPipe.activity-panel-pipe-id.start","time":1288.8999999761581},{"name":"bigPipe.activity-panel-pipe-id.end","time":1290.6000000238419},{"name":"activityTabFullyLoaded","time":1375.5}],"measures":[],"correlationId":"7452d660287888","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":135,"dbReadsTimeInMs":37,"dbConnsTimeInMs":48,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}