Bug #119416 Incorrect in Subquery on MEMORY Engine

Submitted: 18 Nov 2025 6:11 Modified: 7 Dec 2025 21:22
Reporter: little a Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Optimizer Severity:S3 (Non-critical)
Version:9.4.0 OS:Any
Assigned to: CPU Architecture:Any

[18 Nov 2025 6:11] little a
Description:
Just like the test cases

How to repeat:
CREATE TABLE t638 (c1 BIT, c2 NUMERIC (36, 12)) ENGINE MEMORY;
INSERT t638 () VALUES (b'0',-59910194378322.33);
INSERT t638 () VALUES ();

SELECT 0 FROM t638 WHERE (173957000000 NOT IN (SELECT t638.c1 FROM t638));
-- empty set 

Unoptimized Query:
SELECT SUM(count) FROM (SELECT ((173957000000 NOT IN (SELECT t638.c1 FROM t638))) IS TRUE AS count FROM t638) AS TA1;
-- Returned Row Count: 2
[7 Dec 2025 21:22] Roy Lyseng
Verified as described.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.037 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.