Skip to content

Commit 0bbfd5f

Browse files
committed
Add DISTINCTROW keyword (fixes andialbrecht#677).
1 parent 507d3cf commit 0bbfd5f

2 files changed

Lines changed: 7 additions & 0 deletions

File tree

‎CHANGELOG‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Enhancements
77
* Add support for additional SPARK keywords (pr643, by mrmasterplan).
88
* Avoid tokens copy (pr622, by living180).
99
* Add REGEXP as a comparision (pr647, by PeterSandwich).
10+
* Add DISTINCTROW keyword for MS Access (issue677).
1011

1112
Bug Fixes
1213

‎sqlparse/keywords.py‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ def is_keyword(value):
1616
or KEYWORDS_ORACLE.get(val)
1717
or KEYWORDS_PLPGSQL.get(val)
1818
or KEYWORDS_HQL.get(val)
19+
or KEYWORDS_MSACCESS.get(val)
1920
or KEYWORDS.get(val, tokens.Name)), value
2021

2122

@@ -962,3 +963,8 @@ def is_keyword(value):
962963
'BREAK': tokens.Keyword,
963964
'LEAVE': tokens.Keyword,
964965
}
966+
967+
968+
KEYWORDS_MSACCESS = {
969+
'DISTINCTROW': tokens.Keyword,
970+
}

0 commit comments

Comments
 (0)