Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Duplicate
-
12.3.1
-
None
-
ubuntu22.04
-
Not for Release Notes
Description
Summary
Window-function query that compares ROW(...) with a correlated subquery aborts mariadbd via Type_handler_composite::make_sort_key_part().
Environment
- MariaDB 12.3.1-MariaDB-asan-debug
- Built with ASAN/UBSAN
Minimal Reproducer
CREATE DATABASE IF NOT EXISTS logic_bug_focus; |
USE logic_bug_focus; |
|
|
DROP TABLE IF EXISTS t1; |
CREATE TABLE t1 (vkey INT, c5 INT); |
INSERT INTO t1 VALUES (1,1),(2,2),(3,3); |
|
|
SELECT ROW(AVG(vkey) OVER (PARTITION BY vkey), 59) = |
(SELECT ta.vkey, 59 |
FROM t1 ta |
JOIN t1 tb ON (ta.vkey = outer_t.c5) |
LIMIT 1)
|
FROM t1 AS outer_t; |
|
|
DROP TABLE t1; |
Actual Result
- Server terminates immediately with signal 6.
- Client side sees “ERROR 2026 (HY000): TLS/SSL error: unexpected eof while reading” followed by “ERROR 2006: Server has gone away”.
Attachments
Issue Links
- duplicates
-
MDEV-39204 Crash when comparing a ROW(...) expression involving a window function to a correlated row subquery
-
- Confirmed
-