fix test cases

This commit is contained in:
Ganlin Zhao 2023-08-09 17:13:31 +08:00
parent 70e4b4f44e
commit 11823580c7
2 changed files with 4 additions and 4 deletions

View File

@ -2925,7 +2925,7 @@ const SBuiltinFuncDefinition funcMgtBuiltins[] = {
{
.name = "unique",
.type = FUNCTION_TYPE_UNIQUE,
.classification = FUNC_MGT_SELECT_FUNC | FUNC_MGT_INDEFINITE_ROWS_FUNC | FUNC_MGT_FORBID_STREAM_FUNC,
.classification = FUNC_MGT_SELECT_FUNC | FUNC_MGT_INDEFINITE_ROWS_FUNC | FUNC_MGT_FORBID_STREAM_FUNC | FUNC_MGT_IMPLICIT_TS_FUNC,
.translateFunc = translateUnique,
.getEnvFunc = getUniqueFuncEnv,
.initFunc = uniqueFunctionSetup,

View File

@ -438,13 +438,13 @@ class TDTestCase:
tdSql.checkData(0,0,4)
tdSql.checkData(1,0,1)
tdSql.query(f"select unique(c1) v from (select c1 from {dbname}.ct1 partition by c2)")
tdSql.query(f"select unique(c1) v from (select _rowts, c1 from {dbname}.ct1 partition by c2)")
tdSql.checkRows(10)
tdSql.query(f"select unique(c1) v from (select c1 from {dbname}.ct1 order by c2)")
tdSql.query(f"select unique(c1) v from (select _rowts, c1 from {dbname}.ct1 order by c2)")
tdSql.checkRows(10)
tdSql.query(f"select unique(c1) v from (select c1 from {dbname}.ct1 union all select c1 from {dbname}.ct1)")
tdSql.query(f"select unique(c1) v from (select _rowts, c1 from {dbname}.ct1 union all select _rowts, c1 from {dbname}.ct1)")
tdSql.checkRows(10)
# TD-19911