You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-01 06:46:55 +03:00
MCOL-392 Fix negative time handling
This commit is contained in:
@ -165,8 +165,13 @@ int64_t Func_bitand::getIntVal(Row& row,
|
||||
min = 0,
|
||||
sec = 0,
|
||||
msec = 0;
|
||||
// Handle negative correctly
|
||||
if ((time >> 40) & 0xf00)
|
||||
{
|
||||
hour = 0xfffff000;
|
||||
}
|
||||
|
||||
hour = (uint32_t)((time >> 40) & 0xfff);
|
||||
hour |= ((time >> 40) & 0xfff);
|
||||
min = (uint32_t)((time >> 32) & 0xff);
|
||||
sec = (uint32_t)((time >> 24) & 0xff);
|
||||
msec = (uint32_t)(time & 0xffffff);
|
||||
|
Reference in New Issue
Block a user