From c918cc9dc30b3a7684a96feae95fc5c05638360e Mon Sep 17 00:00:00 2001 From: Andi Albrecht Date: Fri, 29 Jul 2011 20:58:14 +0200 Subject: Add parsing of MS Access column names with braces (fixes issue27). --- sqlparse/lexer.py | 1 + 1 file changed, 1 insertion(+) (limited to 'sqlparse') diff --git a/sqlparse/lexer.py b/sqlparse/lexer.py index 950ef1b..ecfdbce 100644 --- a/sqlparse/lexer.py +++ b/sqlparse/lexer.py @@ -189,6 +189,7 @@ class Lexer: (r"(''|'.*?[^\\]')", tokens.String.Single), # not a real string literal in ANSI SQL: (r'(""|".*?[^\\]")', tokens.String.Symbol), + (r'(\[.*[^\]]\])', tokens.Name), (r'(LEFT |RIGHT )?(INNER |OUTER )?JOIN\b', tokens.Keyword), (r'END( IF| LOOP)?\b', tokens.Keyword), (r'NOT NULL\b', tokens.Keyword), -- cgit v1.2.1