-
Notifications
You must be signed in to change notification settings - Fork 558
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
Support Snowflake - allow number as placeholder (e.g. :1
)
#1001
Conversation
Pull Request Test Coverage Report for Build 6639508164
💛 - Coveralls |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @yuval-illumex
@alamb I add failed test and refactored the PR to identify numbers only within placeholder. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @yuval-illumex -- this makes sense to me
@@ -4759,7 +4759,14 @@ impl<'a> Parser<'a> { | |||
Token::HexStringLiteral(ref s) => Ok(Value::HexStringLiteral(s.to_string())), | |||
Token::Placeholder(ref s) => Ok(Value::Placeholder(s.to_string())), | |||
tok @ Token::Colon | tok @ Token::AtSign => { | |||
let ident = self.parse_identifier()?; | |||
// Not calling self.parse_identifier()? because only in placeholder we want to check numbers as idfentifies |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ makes sense to me
// Not calling self.parse_identifier()? because only in placeholder we want to check numbers as idfentifies | |
// Not calling self.parse_identifier()? because only in placeholder we want to check numbers as identifiers |
:1
)
:1
):1
)
The following query is valid in snowflake:
SELECT :1 from table