[MCOL-5192] rowaggregation asserts for agg on char(5) Created: 2022-08-15  Updated: 2023-07-01

Status: Open
Project: MariaDB ColumnStore
Component/s: None
Affects Version/s: None
Fix Version/s: Icebox

Type: Task Priority: Major
Reporter: David Hall (Inactive) Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None


 Description   

We noticed this when testing moda with char type.

Row aggregation will assert if the length of the field isn't = 1,2,4 or 8. The reason being is that it tries to set the accumulator to NULL during start of processing. For small char fields, they're stored as unsigned integers. With a size of 5 (or3,6,7) the function asserts because we don't have predefined values for NULL for these sizes.

See rowaggregation::makeAggFieldsNull()



 Comments   
Comment by David Hall (Inactive) [ 2022-08-15 ]

CREATE TABLE tchar (C1 char(5)) ENGINE=COLUMNSTORE charset latin1;
INSERT tchar VALUES ('t1'),('t2'),('t2'),('t2'),('t3'),('t4'),('t8'),('t8'),('t8');
SELECT MODA(C1) FROM tchar;

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