GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Redshift MATERIALIZED VIEW with AUTO REFRESH is not supported · Issue #1684 · JSQLParser/JSqlParser

Redshift MATERIALIZED VIEW with AUTO REFRESH is not supported #1684

New issue
Copy link
New issue
Copy link
Closed
Closed
Redshift MATERIALIZED VIEW with AUTO REFRESH is not supported#1684
Copy link

Description

@zaza
zaza
opened on Dec 6, 2022
Issue body actions

Using the "AUTO REFRESH" clause for a materialized view in Redshift is not supported by JSqlParser.

Trying to parse a statement like this:
CREATE MATERIALIZED VIEW AUTO REFRESH YES foo AS SELECT * FROM bar
results in:

net.sf.jsqlparser.JSQLParserException: Encountered unexpected token: "CREATE" "CREATE"
    at line 1, column 1.

Was expecting one of:

    "("
    "ALTER"
    "CALL"
    "COMMENT"
    "COMMIT"
    "DECLARE"
    "DELETE"
    "DESCRIBE"
    "DROP"
    "EXEC"
    "EXECUTE"
    "EXPLAIN"
    "GRANT"
    "INSERT"
    "MERGE"
    "PURGE"
    "RENAME"
    "RESET"
    "ROLLBACK"
    "SAVEPOINT"
    "SET"
    "SHOW"
    "TRUNCATE"
    "UPDATE"
    "UPSERT"
    "USE"
    "VALUES"
    "WITH"
    <K_SELECT>

	at app//net.sf.jsqlparser.parser.CCJSqlParserUtil.parseStatement(CCJSqlParserUtil.java:190)
	at app//net.sf.jsqlparser.parser.CCJSqlParserUtil.parse(CCJSqlParserUtil.java:63)
	at app//net.sf.jsqlparser.parser.CCJSqlParserUtil.parse(CCJSqlParserUtil.java:38)
	... 86 more
Caused by: net.sf.jsqlparser.parser.ParseException: Encountered unexpected token: "CREATE" "CREATE"
    at line 1, column 1.

With the AUTO REFRESH YES clause removed the statement is parsed just fine.

Activity

  1. wumpz commented on Dec 10, 2022

    @wumpz
    wumpz
    on Dec 10, 2022
    Member
    More actions

    That's right? Any chance you provide a PR or sponsor this feature?

  2. zaza
    added 3 commits that reference this issue on Dec 11, 2022

    Fixes JSQLParser#1684: Support MATERIALIZED VIEW with AUTO REFRESH

    This issue will close once commit 3086e6a is merged into the 'master' branch.
    3086e6a

    1684: Redshift MATERIALIZED VIEW with AUTO REFRESH is not supported

    This issue will close once commit 3ce274c is merged into the 'master' branch.
    3ce274c

    Fixes JSQLParser#1684: Support CREATE MATERIALIZED VIEW with AUTO REF…

    This issue will close once commit 747152a is merged into the 'master' branch.
    747152a
  3. zaza commented on Dec 11, 2022

    @zaza
    zaza
    on Dec 11, 2022
    ContributorAuthor
    More actions

    This is the PR with an attempt to fix this, see #1691

    Let me know if there are any other changes you would like to see included.

  4. manticore-projects
    added a commit that references this issue on Jan 30, 2023

    feat: CREATE VIEW ... REFRESH AUTO...

    This issue will close once commit 1c8d8da is merged into the 'master' branch.
    1c8d8da
  5. wumpz
    closed this as completedin e71e57don Feb 7, 2023
  6. wumpz
    added a commit that references this issue on Mar 9, 2023

    Assorted Fixes #6 (#1740)

    This issue will close once commit adeed53 is merged into the 'master' branch.
    adeed53
  7. wumpz
    added a commit that references this issue on Mar 21, 2023

    Assorted Fixes #7 (#1745)

    This issue will close once commit 31ef1aa is merged into the 'master' branch.
    31ef1aa
  8. wumpz
    added a commit that references this issue on Apr 27, 2023

    Refactor Parenthesed SelectBody and FromItem (#1754)

    This issue will close once commit a312dcd is merged into the 'master' branch.
    a312dcd
  9. manticore-projects
    added a commit that references this issue on Jun 1, 2023

    JSQLParser 5.0 (#1778)

    This issue will close once commit 41b6fce is merged into the 'master' branch.
    41b6fce
  10. manticore-projects
    added a commit that references this issue on Jun 15, 2023

    Assorted Fixes #8 (#1807)

    This issue will close once commit a815f5f is merged into the 'master' branch.
    a815f5f
  11. manticore-projects
    added a commit that references this issue on Jun 27, 2023

    Backslash Quotation of Single-Quote `'\\''` (#1813)

    This issue will close once commit c79dfff is merged into the 'master' branch.
    c79dfff
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402520 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.