diff options
| -rw-r--r-- | sqlparse/engine/grouping.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/sqlparse/engine/grouping.py b/sqlparse/engine/grouping.py index e30abab..f7953e7 100644 --- a/sqlparse/engine/grouping.py +++ b/sqlparse/engine/grouping.py @@ -220,6 +220,15 @@ def group_typecasts(tlist): @recurse(sql.Function) def group_functions(tlist): + has_create = False + has_table = False + for tmp_token in tlist.tokens: + if tmp_token.value == u'CREATE': + has_create = True + if tmp_token.value == u'TABLE': + has_table = True + if has_create and has_table: + return token = tlist.token_next_by(t=T.Name) while token: next_ = tlist.token_next(token) |
