fix: histogram normalized can only be 0/1
This commit is contained in:
parent
dd7cec4132
commit
e2413a062c
|
@ -1964,6 +1964,9 @@ bool histogramFunctionSetup(SqlFunctionCtx *pCtx, SResultRowEntryInfo *pResultIn
|
|||
}
|
||||
char* binDesc = varDataVal(pCtx->param[2].param.pz);
|
||||
int64_t normalized = pCtx->param[3].param.i;
|
||||
if (normalized != 0 && normalized != 1) {
|
||||
return false;
|
||||
}
|
||||
if (!getHistogramBinDesc(pInfo, binDesc, binType, (bool)normalized)) {
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue