diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-03-02 12:22:00 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-03-02 12:22:00 +0000 |
commit | 3a44ae7d0d4c7f63d7349c26ba4e800cb9f55974 (patch) | |
tree | 7f9ff5ec30175ee816fbbb16333fa0c77cb9d5fd /pgcli/packages/parseutils/tables.py | |
parent | Adding upstream version 3.3.1. (diff) | |
download | pgcli-3a44ae7d0d4c7f63d7349c26ba4e800cb9f55974.tar.xz pgcli-3a44ae7d0d4c7f63d7349c26ba4e800cb9f55974.zip |
Adding upstream version 3.4.0.upstream/3.4.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'pgcli/packages/parseutils/tables.py')
-rw-r--r-- | pgcli/packages/parseutils/tables.py | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/pgcli/packages/parseutils/tables.py b/pgcli/packages/parseutils/tables.py index aaa676c..f2e1e42 100644 --- a/pgcli/packages/parseutils/tables.py +++ b/pgcli/packages/parseutils/tables.py @@ -63,17 +63,13 @@ def extract_from_part(parsed, stop_at_punctuation=True): yield item elif item.ttype is Keyword or item.ttype is Keyword.DML: item_val = item.value.upper() - if ( - item_val - in ( - "COPY", - "FROM", - "INTO", - "UPDATE", - "TABLE", - ) - or item_val.endswith("JOIN") - ): + if item_val in ( + "COPY", + "FROM", + "INTO", + "UPDATE", + "TABLE", + ) or item_val.endswith("JOIN"): tbl_prefix_seen = True # 'SELECT a, FROM abc' will detect FROM as part of the column list. # So this check here is necessary. |