Merge pull request #21497 from taosdata/fix/minSlidingIssue

fix: sliding can't be 1a issue
This commit is contained in:
dapan1121 2023-05-29 10:14:48 +08:00 committed by GitHub
commit 2db1149dd8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 4 deletions

View File

@ -139,8 +139,8 @@ int32_t tsCompressColData = -1;
// count/hyperloglog function always return values in case of all NULL data or Empty data set.
int32_t tsCountAlwaysReturnValue = 1;
// 10 ms for sliding time, the value will changed in case of time precision changed
int32_t tsMinSlidingTime = 10;
// 1 ms for sliding time, the value will changed in case of time precision changed
int32_t tsMinSlidingTime = 1;
// the maxinum number of distict query result
int32_t tsMaxNumOfDistinctResults = 1000 * 10000;
@ -412,7 +412,7 @@ static int32_t taosAddServerCfg(SConfig *pCfg) {
if (cfgAddInt32(pCfg, "maxShellConns", tsMaxShellConns, 10, 50000000, 0) != 0) return -1;
if (cfgAddInt32(pCfg, "statusInterval", tsStatusInterval, 1, 30, 0) != 0) return -1;
if (cfgAddInt32(pCfg, "minSlidingTime", tsMinSlidingTime, 10, 1000000, 0) != 0) return -1;
if (cfgAddInt32(pCfg, "minSlidingTime", tsMinSlidingTime, 1, 1000000, 0) != 0) return -1;
if (cfgAddInt32(pCfg, "minIntervalTime", tsMinIntervalTime, 1, 1000000, 0) != 0) return -1;
if (cfgAddInt32(pCfg, "maxNumOfDistinctRes", tsMaxNumOfDistinctResults, 10 * 10000, 10000 * 10000, 0) != 0) return -1;
if (cfgAddInt32(pCfg, "countAlwaysReturnValue", tsCountAlwaysReturnValue, 0, 1, 0) != 0) return -1;

View File

@ -450,10 +450,11 @@ endi
print ====================>check boundary check crash at client side
sql select count(*) from sliding_mt0 where ts>now and ts < now-1h;
sql select sum(c1) from sliding_tb0 interval(1a) sliding(1a);
print ========================query on super table
print ========================error case
sql_error select sum(c1) from sliding_tb0 interval(1a) sliding(1a);
sql_error select sum(c1) from sliding_tb0 interval(10a) sliding(12a);
sql_error select sum(c1) from sliding_tb0 sliding(1n) interval(1y);
sql_error select sum(c1) from sliding_tb0 interval(-1y) sliding(1n);