[MCOL-3787] CS doesn't apply having with impossible condition on top of aggregation Created: 2020-02-12  Updated: 2023-10-25  Resolved: 2023-10-25

Status: Closed
Project: MariaDB ColumnStore
Component/s: ExeMgr
Affects Version/s: 1.4.2
Fix Version/s: Icebox

Type: Bug Priority: Minor
Reporter: Roman Assignee: Unassigned
Resolution: Won't Do Votes: 0
Labels: None

Issue Links:
Relates
relates to MCOL-3769 Impossible WHERE and HAVING condition... Closed

 Description   

Consider example.

MariaDB [test]> select sum(i) from cs1 HAVING -1 != -1;
+--------+
| sum(i) |
+--------+
|   NULL |
+--------+
1 row in set, 1 warning (0.012 sec)
 
MariaDB [test]> select calgettrace(0)\G
*************************** 1. row ***************************
calgettrace(0): 
Desc Mode Table TableOID ReferencedColumns PIO LIO PBE Elapsed Rows 
TCS  UM   -     -        -                 -   -   -   0.000   0    
TAS  UM   -     -        -                 -   -   -   0.000   1    
TNS  UM   -     -        -                 -   -   -   0.000   1    
 
1 row in set (0.000 sec)
 
MariaDB [test]> 

Innodb table returns an empty set for the same query meanwhile. CS doesn't have having in TNS when HAVING has impossible conditions.


Generated at Thu Feb 08 02:45:26 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.