mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-04 13:32:13 +00:00
check max H3 resolution
This commit is contained in:
parent
a680604335
commit
f0bffbfee5
@ -69,7 +69,12 @@ public:
|
||||
|
||||
for (size_t row = 0; row < input_rows_count; ++row)
|
||||
{
|
||||
const UInt64 resolution = data[row];
|
||||
const int resolution = data[row];
|
||||
if (resolution > MAX_H3_RES)
|
||||
throw Exception(
|
||||
ErrorCodes::ARGUMENT_OUT_OF_BOUND,
|
||||
"The argument 'resolution' ({}) of function {} is out of bounds because the maximum resolution in H3 library is ",
|
||||
resolution, getName(), MAX_H3_RES);
|
||||
Float64 res = getNumCells(resolution);
|
||||
dst_data[row] = res;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user