Repository: tobymao/sqlglot

Issue:
[spark dialect] Parser doesn't work when table alias is "div"
reproduction:

```python
sql = """select div.a from test_table div"""
parse_one(sql, read='spark')
```

error:
```python
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/__init__.py", line 84, in parse_one
    result = dialect.parse(sql, **opts)
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/dialects/dialect.py", line 150, in parse
    return self.parser(**opts).parse(self.tokenizer.tokenize(sql), sql)
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 666, in parse
    return self._parse(
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 727, in _parse
    expressions.append(parse_method(self))
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 877, in _parse_statement
    expression = self._parse_set_operations(expression) if expression else self._parse_select()
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 1259, in _parse_select
    expressions = self._parse_csv(self._parse_expression)
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 2840, in _parse_csv
    parse_result = parse_method()
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 1838, in _parse_expression
    return self._parse_alias(self._parse_conjunction())
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 1841, in _parse_conjunction
    return self._parse_tokens(self._parse_equality, self.CONJUNCTION)
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 2856, in _parse_tokens
    this = parse_method()
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 1844, in _parse_equality
    return self._parse_tokens(self._parse_comparison, self.EQUALITY)
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 2856, in _parse_tokens
    this = parse_method()
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 1847, in _parse_comparison
    return self._parse_tokens(self._parse_range, self.COMPARISON)
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 2856, in _parse_tokens
    this = parse_method()
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 1850, in _parse_range
    this = self._parse_bitwise()
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 1915, in _parse_bitwise
    this = self._parse_term()
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 1938, in _parse_term
    return self._parse_tokens(self._parse_factor, self.TERM)
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 2856, in _parse_tokens
    this = parse_method()
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 1941, in _parse_factor
    return self._parse_tokens(self._parse_unary, self.FACTOR)
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 2859, in _parse_tokens
    this = self.expression(
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 797, in expression
    self.validate_expression(instance)
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 820, in validate_expression
    self.raise_error(f"Required keyword: '{k}' missing for {expression.__class__}")
  File "/opt/homebrew/lib/python3.8/site-packages/sqlglot/parser.py", line 773, in raise_error
    raise error
sqlglot.errors.ParseError: Required keyword: 'this' missing for <class 'sqlglot.expressions.IntDiv'>. Line 1, Col: 11.
  select div.a from test_table div
```


Discussion:

Resolving patch:
diff --git a/sqlglot/parser.py b/sqlglot/parser.py
--- a/sqlglot/parser.py
+++ b/sqlglot/parser.py
@@ -171,6 +171,7 @@ class Parser(metaclass=_Parser):
         TokenType.DELETE,
         TokenType.DESCRIBE,
         TokenType.DETERMINISTIC,
+        TokenType.DIV,
         TokenType.DISTKEY,
         TokenType.DISTSTYLE,
         TokenType.EXECUTE,


Test patch:
diff --git a/tests/fixtures/identity.sql b/tests/fixtures/identity.sql
--- a/tests/fixtures/identity.sql
+++ b/tests/fixtures/identity.sql
@@ -636,3 +636,4 @@ ALTER TABLE integers ALTER COLUMN i SET DEFAULT 10
 ALTER TABLE integers ALTER COLUMN i DROP DEFAULT
 ALTER TABLE mydataset.mytable DROP COLUMN A, DROP COLUMN IF EXISTS B
 ALTER TABLE mydataset.mytable ADD COLUMN A TEXT, ADD COLUMN IF NOT EXISTS B INT
+SELECT div.a FROM test_table AS div