[Bugfix] Remove prequery properties from query_obj (#7896)

* Create query_obj for every filter

* Deprecate is_prequery and prequeries from query_obj

* Fix tests

* Fix typos and remove redundant ; from sql

* Add typing to namedtuples and move all query str logic to one place

* Fix unit test
This commit is contained in:
Ville Brofeldt
2019-07-23 22:13:58 +03:00
committed by GitHub
parent 2221445f44
commit 07a76f83b1
12 changed files with 48 additions and 66 deletions

View File

@@ -117,9 +117,9 @@ class BaseEngineSpec(object):
time_groupby_inline = False
limit_method = LimitMethod.FORCE_LIMIT
time_secondary_columns = False
inner_joins = True
allows_subquery = True
supports_column_aliases = True
allows_joins = True
allows_subqueries = True
allows_column_aliases = True
force_column_alias_quotes = False
arraysize = 0
max_column_name_length = 0

View File

@@ -22,8 +22,8 @@ class DruidEngineSpec(BaseEngineSpec):
"""Engine spec for Druid.io"""
engine = "druid"
inner_joins = False
allows_subquery = True
allows_joins = False
allows_subqueries = True
time_grain_functions = {
None: "{col}",

View File

@@ -22,5 +22,5 @@ class GSheetsEngineSpec(SqliteEngineSpec):
"""Engine for Google spreadsheets"""
engine = "gsheets"
inner_joins = False
allows_subquery = False
allows_joins = False
allows_subqueries = False

View File

@@ -24,9 +24,9 @@ from superset.db_engine_specs.base import BaseEngineSpec, TimestampExpression
class PinotEngineSpec(BaseEngineSpec):
engine = "pinot"
allows_subquery = False
inner_joins = False
supports_column_aliases = False
allows_subqueries = False
allows_joins = False
allows_column_aliases = False
# Pinot does its own conversion below
time_grain_functions: Dict[Optional[str], str] = {