Unify dimension min handling

PR #6737 introduced a new function to determine the min value for a
given data type. This patch uses the function in a further place.
This commit is contained in:
Jan Nidzwetzki 2024-03-13 17:00:41 +01:00 committed by Jan Nidzwetzki
parent 5ac02241c2
commit 95baf1e6f3

View File

@ -119,11 +119,8 @@ policy_refresh_cagg_get_refresh_start(const ContinuousAgg *cagg, const Dimension
/* interpret NULL as min value for that type */ /* interpret NULL as min value for that type */
if (*start_isnull) if (*start_isnull)
{ {
Oid type = ts_dimension_get_partition_type(dim); Assert(cagg->partition_type == ts_dimension_get_partition_type(dim));
return cagg_get_time_min(cagg);
return cagg->bucket_function->bucket_fixed_interval == false ?
ts_time_get_nobegin_or_min(type) :
ts_time_get_min(type);
} }
return res; return res;