From 9cd9b91412734f8f084439690082f9e699ebd89e Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Mon, 12 Sep 2022 07:42:24 +0300 Subject: Fix query: Add comma to separate columns. --- wqflask/base/data_set.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wqflask/base/data_set.py b/wqflask/base/data_set.py index 02e6cefe..9685e33e 100644 --- a/wqflask/base/data_set.py +++ b/wqflask/base/data_set.py @@ -784,7 +784,8 @@ class DataSet: else: query = "SELECT {}.Name".format(escape(dataset_type)) data_start_pos = 1 - query += ', '.join(temp) + if len(temp) > 0: + query = query + ", " + ', '.join(temp) query += ' FROM ({}, {}XRef, {}Freeze) '.format(*mescape(dataset_type, self.type, self.type)) -- cgit v1.2.3