Greenplum Keyword Compatibility Reference¶
Generated for GSP Java version 4.1.9 on 2026-07-29
This page was generated using hybrid static extraction from parser source files combined with runtime validation against the actual GSP parser. Re-run the extraction script after parser updates to keep this page current.
Keyword-as-Column-Name Support¶
As of version 4.1.0.8, the GSP Greenplum parser includes a targeted lexer lookahead mechanism that disambiguates keywords based on their surrounding token context (e.g., function keywords are only converted when NOT followed by ().
Full Classification Overview¶
Out of 519 keywords recognized by the GSP Greenplum parser:
| Classification | Count | Description |
|---|---|---|
| Allowed | 466 | Can be used as an unquoted column name in both canonical contexts |
| Context-specific | 52 | Fails as SELECT keyword FROM t but works as SELECT t.keyword FROM t |
| Blocked | 1 | Cannot be used as an unquoted column name in either context |
Context-Specific Keywords (52)¶
These keywords parse in one canonical context but not the other (measured against the release stamped above).
| Keyword | SELECT kw FROM t |
SELECT t.kw FROM t |
|---|---|---|
ALL |
no | yes |
ARRAY |
no | yes |
AUTHORIZATION |
no | yes |
BIT |
no | yes |
BOOLEAN |
no | yes |
CASE |
no | yes |
CAST |
no | yes |
CHAR |
no | yes |
COALESCE |
no | yes |
CONCURRENTLY |
no | yes |
CROSS |
no | yes |
DEC |
no | yes |
DECIMAL |
no | yes |
DISTINCT |
no | yes |
FLOAT |
no | yes |
FREEZE |
no | yes |
FULL |
no | yes |
GREATEST |
no | yes |
ILIKE |
no | yes |
INTEGER |
no | yes |
INTERVAL |
no | yes |
IS |
no | yes |
JOIN |
no | yes |
LEAST |
no | yes |
LEFT |
no | yes |
LIKE |
no | yes |
NATIONAL |
no | yes |
NATURAL |
no | yes |
NCHAR |
no | yes |
NOT |
no | yes |
NULLIF |
no | yes |
NUMERIC |
no | yes |
OUTER |
no | yes |
OVERLAPS |
no | yes |
OVERLAY |
no | yes |
REAL |
no | yes |
RIGHT |
no | yes |
ROW |
no | yes |
SIMILAR |
no | yes |
SMALLINT |
no | yes |
SUBSTRING |
no | yes |
TREAT |
no | yes |
VARCHAR |
no | yes |
VERBOSE |
no | yes |
XMLCONCAT |
no | yes |
XMLELEMENT |
no | yes |
XMLEXISTS |
no | yes |
XMLFOREST |
no | yes |
XMLPARSE |
no | yes |
XMLPI |
no | yes |
XMLROOT |
no | yes |
XMLSERIALIZE |
no | yes |
Blocked Keywords (1)¶
These keywords fail as unquoted identifiers in both canonical contexts. Workaround: quote the identifier (e.g. "KEYWORD").
| Keyword |
|---|
FROM |
Workaround: Double-Quoted Identifiers¶
For any keyword that fails as an unquoted column name, you can use double-quoted identifiers:
1 2 3 4 5 | |
Scope and Limitations¶
- Tested contexts:
SELECT keyword FROM tandSELECT t.keyword FROM t. Other contexts (DDL column definitions, INSERT column lists, aliases) may behave differently. - Version-specific: This report reflects GSP Java version 4.1.0.8.
- Case sensitivity: Keywords are case-insensitive.
select,SELECT, andSelectare all treated the same.
How to Report Discrepancies¶
If you encounter a keyword that behaves differently from what this page describes, please report it through your support channel. Include:
- The exact SQL statement
- The GSP parser version
- Whether the same SQL works in Greenplum
Methodology¶
- Static extraction: A Python script parses the lexer (
.cod) and grammar (.y) source files to identify all 519 keywords and their grammar classifications. - Runtime validation: A Java test harness validates every classification against actual
TGSqlParserruntime behavior. - JSON dataset: The authoritative data is stored in
docs/generated/greenplum_keyword_compatibility.json.