1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-07 00:04:31 +03:00

Merge 10.5 into 10.6

This commit is contained in:
Marko Mäkelä
2022-09-20 16:53:20 +03:00
1152 changed files with 30607 additions and 29546 deletions

View File

@@ -219,7 +219,7 @@ t1 CREATE TABLE `t1` (
`g` geometry NOT NULL,
`p` point DEFAULT NULL,
`p1` point DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
INSERT INTO t1 VALUES(ST_PointFromText('POINT(0.5 0.5)'), ST_PointFromText('POINT(0 1)'), ST_PointFromText('POINT(10 19)'));
INSERT INTO t1 VALUES(ST_PointFromText('POINT(0.6 0.6)'), ST_PointFromText('POINT(1 1)'), ST_PointFromText('POINT(10 20)'));
INSERT INTO t1 VALUES(ST_PointFromText('POINT(0.7 0.7)'), ST_PointFromText('POINT(1 0)'), ST_PointFromText('POINT(10 21)'));
@@ -1428,7 +1428,7 @@ geom CREATE TABLE `geom` (
`i` int(11) DEFAULT NULL,
`g` point NOT NULL,
SPATIAL KEY `g` (`g`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
SELECT ST_AsText(g) FROM geom;
ST_AsText(g)
POINT(0 0)
@@ -1441,7 +1441,7 @@ geom CREATE TABLE `geom` (
`i` int(11) DEFAULT NULL,
`g` geometry NOT NULL,
SPATIAL KEY `g` (`g`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
TRUNCATE TABLE geom;
From GEOMETRY to POINT, the table is empty
ALTER TABLE geom MODIFY g POINT NOT NULL;
@@ -1451,7 +1451,7 @@ geom CREATE TABLE `geom` (
`i` int(11) DEFAULT NULL,
`g` point NOT NULL,
SPATIAL KEY `g` (`g`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
SELECT ST_AsText(g) FROM geom;
ST_AsText(g)
CHECK TABLE gis_point;
@@ -1517,7 +1517,7 @@ t1 CREATE TABLE `t1` (
SPATIAL KEY `idx2` (`p`),
SPATIAL KEY `idx3` (`l`),
SPATIAL KEY `idx4` (`g`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
SELECT a, ST_AsText(p), ST_AsText(l), ST_AsText(g) FROM t1;
a ST_AsText(p) ST_AsText(l) ST_AsText(g)
1 POINT(10 10) LINESTRING(1 1,5 5,10 10) POLYGON((30 30,40 40,50 50,30 50,30 40,30 30))
@@ -1551,13 +1551,13 @@ parent CREATE TABLE `parent` (
`p` point NOT NULL,
PRIMARY KEY (`p`(25)),
SPATIAL KEY `idx1` (`p`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
SHOW CREATE TABLE child;
Table Create Table
child CREATE TABLE `child` (
`p` point NOT NULL,
SPATIAL KEY `idx2` (`p`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
ALTER TABLE child ADD FOREIGN KEY(p) REFERENCES parent(p);
ERROR HY000: Can't create table `test`.`child` (errno: 150 "Foreign key constraint is incorrectly formed")
show warnings;