Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for view comments for Snowflake #1287

Merged
merged 4 commits into from
May 30, 2024

Conversation

bombsimon
Copy link
Contributor

Snowflake supports adding a comment when creating a view, see https://docs.snowflake.com/en/sql-reference/sql/create-view#syntax.

@coveralls
Copy link

coveralls commented May 24, 2024

Pull Request Test Coverage Report for Build 9265999109

Details

  • 61 of 64 (95.31%) changed or added relevant lines in 6 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.01%) to 89.49%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/parser/mod.rs 9 10 90.0%
src/ast/mod.rs 4 6 66.67%
Totals Coverage Status
Change from base Build 9212358328: 0.01%
Covered Lines: 24981
Relevant Lines: 27915

💛 - Coveralls

src/parser/mod.rs Outdated Show resolved Hide resolved
src/parser/mod.rs Outdated Show resolved Hide resolved
src/parser/mod.rs Outdated Show resolved Hide resolved
tests/sqlparser_common.rs Outdated Show resolved Hide resolved
- Support `GenericDialect` as well
- Inline keyword match
- Use `expect_token` instead of `consume_token` for the equal sign
- Fix faulty expect text
- Move test to `sqlparser_snowflake.rs`
- Add negative test for missing equal sign
@bombsimon bombsimon requested a review from iffyio May 26, 2024 19:52
Copy link
Contributor

@jmhain jmhain left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, modulo the missing string escape cc @alamb

src/ast/mod.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the contributon @bombsimon and thank you for the reviews @iffyio and @jmhain

@alamb alamb merged commit 029a999 into apache:main May 30, 2024
10 checks passed
@iffyio iffyio deleted the snowflake-comments branch July 16, 2024 11:38
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.

5 participants