summaryrefslogtreecommitdiffstats
path: root/sqlglot/dataframe/sql/operations.py
diff options
context:
space:
mode:
Diffstat (limited to 'sqlglot/dataframe/sql/operations.py')
-rw-r--r--sqlglot/dataframe/sql/operations.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/sqlglot/dataframe/sql/operations.py b/sqlglot/dataframe/sql/operations.py
index d51335c..e4c106b 100644
--- a/sqlglot/dataframe/sql/operations.py
+++ b/sqlglot/dataframe/sql/operations.py
@@ -41,7 +41,7 @@ def operation(op: Operation):
self.last_op = Operation.NO_OP
last_op = self.last_op
new_op = op if op != Operation.NO_OP else last_op
- if new_op < last_op or (last_op == new_op and new_op == Operation.SELECT):
+ if new_op < last_op or (last_op == new_op == Operation.SELECT):
self = self._convert_leaf_to_cte()
df: t.Union[DataFrame, GroupedData] = func(self, *args, **kwargs)
df.last_op = new_op # type: ignore