mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 15:12:02 +00:00
Fixed ASOF JOIN with DateTime64, updated test case for comparison.
This commit is contained in:
parent
eb9604ecd0
commit
fb712c4a4a
@ -39,6 +39,7 @@ void callWithType(TypeIndex which, F && f)
|
||||
case TypeIndex::Decimal32: return f(Decimal32());
|
||||
case TypeIndex::Decimal64: return f(Decimal64());
|
||||
case TypeIndex::Decimal128: return f(Decimal128());
|
||||
case TypeIndex::DateTime64: return f(DateTime64());
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@ -153,6 +154,9 @@ std::optional<TypeIndex> AsofRowRefs::getTypeSize(const IColumn & asof_column, s
|
||||
case TypeIndex::Decimal128:
|
||||
size = sizeof(Decimal128);
|
||||
return idx;
|
||||
case TypeIndex::DateTime64:
|
||||
size = sizeof(DateTime64);
|
||||
return idx;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -228,7 +228,8 @@ public:
|
||||
Entry<Float64>::LookupPtr,
|
||||
Entry<Decimal32>::LookupPtr,
|
||||
Entry<Decimal64>::LookupPtr,
|
||||
Entry<Decimal128>::LookupPtr>;
|
||||
Entry<Decimal128>::LookupPtr,
|
||||
Entry<DateTime64>::LookupPtr>;
|
||||
|
||||
AsofRowRefs() {}
|
||||
AsofRowRefs(TypeIndex t);
|
||||
|
@ -1,3 +1,3 @@
|
||||
2019-09-16 19:20:33.123000 2019-09-16 19:20:33.123 0 1 1 1 0
|
||||
2015-05-18 07:40:29.123456 2019-09-16 19:20:33.123 0 0 0 1 1
|
||||
2019-09-16 19:20:33.123456 2015-05-18 07:40:29.123 1 1 0 0 0
|
||||
2015-05-18 07:40:29.123456 2019-09-16 19:20:33.123 0 0 0 1 1 1
|
||||
2019-09-16 19:20:33.123000 2019-09-16 19:20:33.123 0 1 1 1 0 0
|
||||
2019-09-16 19:20:33.123456 2015-05-18 07:40:29.123 1 1 0 0 0 1
|
||||
|
@ -14,7 +14,8 @@ SELECT
|
||||
dt6 >= dt3,
|
||||
dt6 = dt3,
|
||||
dt6 <= dt3,
|
||||
dt6 < dt3
|
||||
dt6 < dt3,
|
||||
dt6 != dt3
|
||||
FROM datetime64_cmp
|
||||
ORDER BY
|
||||
dt6, dt3;
|
||||
|
Loading…
Reference in New Issue
Block a user