Fix tests

This commit is contained in:
Amos Bird 2021-03-03 22:26:55 +08:00
parent 93b661ad5a
commit 2f8f4e9697
No known key found for this signature in database
GPG Key ID: 80D430DCBECFEDB4
3 changed files with 6 additions and 1 deletions

View File

@ -41,6 +41,10 @@ bool isValidFunction(const ASTPtr & expression, const NameSet & columns)
if (!isValidFunction(function->arguments->children[0], columns))
return false;
}
else if (function->name == "ignore")
{
return false;
}
else
{
if (function->arguments)

View File

@ -8,7 +8,7 @@ INSERT INTO xp SELECT '2020-01-01', number, '' FROM numbers(100000);
CREATE TABLE xp_d AS xp ENGINE = Distributed(test_shard_localhost, currentDatabase(), xp);
SELECT count(7 = (SELECT number FROM numbers(0) ORDER BY number ASC NULLS FIRST LIMIT 7)) FROM xp_d PREWHERE toYYYYMM(A) GLOBAL IN (SELECT NULL = (SELECT number FROM numbers(1) ORDER BY number DESC NULLS LAST LIMIT 1), toYYYYMM(min(A)) FROM xp_d) WHERE B > NULL; -- { serverError 20 }
SELECT count(7 = (SELECT number FROM numbers(0) ORDER BY number ASC NULLS FIRST LIMIT 7)) FROM xp_d PREWHERE toYYYYMM(A) GLOBAL IN (SELECT NULL = (SELECT number FROM numbers(1) ORDER BY number DESC NULLS LAST LIMIT 1), toYYYYMM(min(A)) FROM xp_d) WHERE B > NULL; -- B > NULL is evaluated to 0 and this works
SELECT count() FROM xp_d WHERE A GLOBAL IN (SELECT NULL); -- { serverError 53 }