Details
-
Bug
-
Status: Stalled (View Workflow)
-
Critical
-
Resolution: Unresolved
-
10.6.1, 10.2.39, 10.3.30, 10.4.20, 10.5.11
-
None
Description
Simple table with two colums Type(varchar) and Point(point)
An index on Type(Tindex) and a spatial index on Point(Pindex)
Now a query like
SELECT X(Point) as x,Y(Point) as y,hotels.Type FROM hotels WHERE (Type in ("acco")) AND MBRContains( GeomFromText( 'LINESTRING(4.922 52.909,5.625 52.483)' ), hotels.Point) |
;
|
Results in a
Error in query (1207): Update locks cannot be acquired during a READ UNCOMMITTED transaction
While both
SELECT X(Point) as x,Y(Point) as y,hotels.Type FROM hotels USE INDEX (Pindex) WHERE (Type in ("acco")) AND MBRContains( GeomFromText( 'LINESTRING(4.922 52.909,5.625 52.483)' ), hotels.Point) |
;
|
and
SELECT X(Point) as x,Y(Point) as y,hotels.Type FROM hotels USE INDEX (Tindex) WHERE (Type in ("acco")) AND MBRContains( GeomFromText( 'LINESTRING(4.922 52.909,5.625 52.483)' ), hotels.Point) |
;
|
work fine. As mariadb 10.5.10 did
id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
1 | SIMPLE | hotels | range | filter | Type,Pindex | Pindex | Type | 34 | 302 | NULL | 340 (4%) | Using where; Using rowid filter |
Attachments
Issue Links
- duplicates
-
MDEV-26204 Update locks cannot be acquired during a READ UNCOMMITTED transaction with SELECT
-
- Closed
-
- is caused by
-
MDEV-25594 Crash in deadlock checker under high load
-
- Closed
-
- is duplicated by
-
MDEV-35742 Predicates under spatial index cause transaction errors
-
- Closed
-
- relates to
-
MDEV-14059 InnoDB assertion failure offset >= ((38U + 36 + 2 * 10) + 5) at page0page.h line 318
-
- Closed
-
-
MDEV-15275 innodb_gis.rtree_purge failed in buildbot with timeout
-
- Open
-
-
MDEV-15284 innodb_gis.rtree_concurrent_srch fails with COUNT(*) mismatch
-
- Confirmed
-
- links to
vlad.lesin, I introduced that debug check when reimplementing the buffer page latches in MariaDB Server 10.6. The assertion fails because an exclusively held latch is being freed. This is related to the question that was left unanswered in
MDEV-14059. Why are buffer page descriptors being copied in some SPATIAL INDEX operations? Could it be avoided?That is not the only peculiarity in SPATIAL INDEX locking. What are the tweaks in the purge of history needed for? Can some garbage in SPATIAL INDEX be left behind by the purge of history if there was some locking conflict when the purge was attempted? Why is there a race condition between MVCC and ROLLBACK (MDEV-15284)?
I think that we must first understand how the locking on MySQL 5.7 SPATIAL INDEX was supposed to work. This is not an easy task.