iffyio commented on code in PR #2004: URL: https://github.com/apache/datafusion-sqlparser-rs/pull/2004#discussion_r2287939192
########## src/parser/mod.rs: ########## @@ -4713,7 +4713,10 @@ impl<'a> Parser<'a> { let create_view_params = self.parse_create_view_params()?; if self.parse_keyword(Keyword::TABLE) { self.parse_create_table(or_replace, temporary, global, transient) - } else if self.parse_keyword(Keyword::MATERIALIZED) || self.parse_keyword(Keyword::VIEW) { + } else if self.parse_keyword(Keyword::MATERIALIZED) + || self.parse_keyword(Keyword::VIEW) + || (dialect_of!(self is SnowflakeDialect) && self.parse_keyword(Keyword::SECURE)) + { self.prev_token(); Review Comment: ```suggestion } else if self.peek_keyword(Keyword::MATERIALIZED) || self.peek_keyword(Keyword::VIEW) || self.peek_keywords(&[Keyword::SECURE, Keyword::MATERIALIZED]) || self.peek_keywords(&[Keyword::SECURE, Keyword::VIEW]) || (dialect_of!(self is SnowflakeDialect) && self.parse_keyword(Keyword::SECURE)) { ``` We could probably do something like this? also I imagine no need for the snowflakeDialect check since the syntax doesn't conflict with other dialects. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org