From bd4aa82d19feb8729edf778baffaaab22e5c4a0d Mon Sep 17 00:00:00 2001 From: jiacy-jcy Date: Tue, 12 Jul 2022 15:57:40 +0800 Subject: [PATCH] update case --- tests/system-test/2-query/percentile.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/tests/system-test/2-query/percentile.py b/tests/system-test/2-query/percentile.py index 06b9ada4ba..43b5c5610a 100644 --- a/tests/system-test/2-query/percentile.py +++ b/tests/system-test/2-query/percentile.py @@ -134,10 +134,15 @@ class TDTestCase: tdSql.query(f'select percentile({k}, {param}) from {self.stbname}_{i}') tdSql.checkData(0, 0, np.percentile(floatData, param)) - #!bug TD-17119 - # for k,v in self.tag_dict.items(): - # for param in self.param: - # tdSql.error(f'select percentile({k},{param}) from {self.stbname}_{i}') + for k,v in self.tag_dict.items(): + for param in self.param: + if v.lower() in ['timestamp','bool'] or 'binary' in v.lower() or 'nchar' in v.lower(): + tdSql.error(f'select percentile({k},{param}) from {self.stbname}_{i}') + else: + tdSql.query(f'select {k} from {self.stbname}_{i}') + data_num = tdSql.queryResult[0][0] + tdSql.query(f'select percentile({k},{param}) from {self.stbname}_{i}') + tdSql.checkData(0,0,data_num) def run(self): self.function_check_ntb() -- GitLab