-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
evalengine: More functions! #9673
Conversation
Signed-off-by: Vicent Marti <[email protected]>
Signed-off-by: Vicent Marti <[email protected]>
Signed-off-by: Vicent Marti <[email protected]>
Signed-off-by: Vicent Marti <[email protected]>
Signed-off-by: Vicent Marti <[email protected]>
Signed-off-by: Vicent Marti <[email protected]>
350c259
to
1f95837
Compare
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.
All the changes look good to me. The shift-reduce conflict in the parser is unavoidable because we have a catch-all statement for functions in the end. Until, we remove it, any function which is a non-reserved keyword will have shift-reduce conflicts.
However, the check_make_parser.sh
has to be fixed to expect a conflict
Signed-off-by: Vicent Marti <[email protected]>
Signed-off-by: Vicent Marti <[email protected]>
Signed-off-by: Vicent Marti <[email protected]>
@@ -86,6 +86,8 @@ func TestConvertSimplification(t *testing.T) { | |||
{"coalesce(NULL, 2, NULL, 4)", ok("COALESCE(NULL, INT64(2), NULL, INT64(4))"), ok("INT64(2)")}, | |||
{"coalesce(NULL, NULL)", ok("COALESCE(NULL, NULL)"), ok("NULL")}, | |||
{"coalesce(NULL)", ok("COALESCE(NULL)"), ok("NULL")}, | |||
{"weight_string('foobar')", ok(`WEIGHT_STRING(VARCHAR("foobar"))`), ok(`VARBINARY("\x00F\x00O\x00O\x00B\x00A\x00R")`)}, | |||
{"weight_string('foobar' as char(12))", ok(`WEIGHT_STRING(VARCHAR("foobar") AS CHAR(12))`), ok(`VARBINARY("\x00F\x00O\x00O\x00B\x00A\x00R\x00 \x00 \x00 \x00 \x00 \x00 ")`)}, |
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.
shouldn't we also add the bit operations to this test?
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.
The bit operations are integration tested in the major suite.
Description
Hot off the press! New functionality for the
evalengine
. This PR implements and tests:WEIGHT_STRING
: useful to ensure our collations implementation is actually working (spoiler: it is). This includes some changes to the sqlparser becauseWEIGHT_STRING
has special syntax.!
operator (which is an alias forNOT
)&
,|
,^
,<<
,>>
,~
, andBIT_COUNT
bit-wise operatorsRelated Issue(s)
Checklist
Deployment Notes