Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
10.6, 10.11, 11.4, 11.8, 12.3, 13.0
-
Can result in unexpected behaviour
Description
--source include/have_innodb.inc
|
CREATE TABLE t(c INT,c2 TEXT) ENGINE=InnoDB; |
SET @@SESSION.sort_buffer_size=30839; # up to 30839: error, 30840: no error |
SELECT c,LAG(c,1) OVER w FROM t WINDOW w AS (PARTITION BY c2 ORDER BY c2); |
DROP TABLE t; # Cleanup |
Leads to:
|
CS 13.0.1 3a2f8e27981b76b99d2b87cc3bcec5ef022b2b23 (Debug, Clang 21.1.3-20250923) Build 10/04/2026 |
mysqltest: At line 12: query 'SELECT c,LAG(c,1) OVER w FROM t WINDOW w AS (PARTITION BY c2 ORDER BY c2)' failed: ER_OUT_OF_SORTMEMORY (1038): Out of sort memory, consider increasing server sort buffer size
|
Present in all versions. Interesting that changing it from 30839 to 30840 specifically makes it work.