Bug #117094 Using TRUE and * in SELECT returns different row counts.

Submitted: 2 Jan 2025 6:31 Modified: 2 Jan 2025 7:34
Reporter: wang jack Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: DML Severity:S3 (Non-critical)
Version:8.4.1, 8.0.40 OS:Windows (windows 11)
Assigned to: CPU Architecture:Any (x86_64)

[2 Jan 2025 6:31] wang jack
Description:
I believe the following two queries should return the same number of rows.
However, that is not the case.

select * from t0; -- empty
select TRUE from t0; -- 2 rows

How to repeat:
DROP TABLE IF EXISTS t0;
CREATE TABLE t0(c0 DOUBLE) ;
CREATE INDEX i50 USING HASH ON t0((((STRCMP((-17887440) IN (0.9053216704935246), (- (t0.c0)))) IN ((".ဖSr#.") IS NOT TRUE)) IS NULL));
INSERT HIGH_PRIORITY IGNORE INTO t0(c0) VALUES(NULL), (86417285), (0.643481491684385);
DELETE QUICK FROM t0; -- ERROR 3751 (01000): Data truncated for functional index 'i50' at row 1
DELETE IGNORE FROM t0;

select * from t0; -- empty
select TRUE from t0; -- 2 rows
[2 Jan 2025 7:34] MySQL Verification Team
Hello wang jack,

Thank you for the report and test case.

regards,
Umesh

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

Page generated in 0.049 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.