Skip to content

HCK-16464: Tables and view REed from the instance with limited number of columns and weird dummy text#348

Merged
chulanovskyi-bs merged 5 commits into
developfrom
HCK-16464
Jun 19, 2026
Merged

HCK-16464: Tables and view REed from the instance with limited number of columns and weird dummy text#348
chulanovskyi-bs merged 5 commits into
developfrom
HCK-16464

Conversation

@Nightlngale

@Nightlngale Nightlngale commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Technical details

The grammar contained two lexer rules for the same word DEFAULT:

  • DEFAULT
  • KW_DEFAULT

Both matched the string DEFAULT, but ANTLR’s lexer always picks the first matching rule. As a result, the token stream contains DEFAULT only, never KW_DEFAULT.

Several parser rules still expected KW_DEFAULT (e.g. column DEFAULT constraints and GENERATED BY DEFAULT AS IDENTITY), which caused DDL parsing to fail during reverse engineering from instance.

I consolidated the grammar to use a single runtime token, DEFAULT, updated the affected parser rules, regenerated the ANTLR output, and adapted the visitor accordingly.

Also updated the logic of fetching views

@Nightlngale Nightlngale self-assigned this Jun 18, 2026
@Nightlngale Nightlngale changed the title HCK-16464: Update parser HCK-16464: Tables and view REed from the instance with limited number of columns and weird dummy text Jun 18, 2026
@Nightlngale Nightlngale marked this pull request as ready for review June 18, 2026 15:28
@chulanovskyi-bs chulanovskyi-bs enabled auto-merge (squash) June 19, 2026 07:14
@chulanovskyi-bs chulanovskyi-bs merged commit 2bcf828 into develop Jun 19, 2026
8 checks passed
@chulanovskyi-bs chulanovskyi-bs deleted the HCK-16464 branch June 19, 2026 07:41
@sonarqubecloud

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants