-
Notifications
You must be signed in to change notification settings - Fork 60
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
TIMESTAMP support integer #230
Conversation
issue 229
@@ -17,6 +17,10 @@ import ( | |||
"gopkg.in/yaml.v2" | |||
) | |||
|
|||
var ( | |||
reTimestampInteger = regexp.MustCompile(`^(0[xX][0-9a-fA-F]+|0[0-7]+|\d+)$`) |
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.
0o
prefix represent the octal number
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.
I've tried.
(root@nebula) [importer_test_v2]> RETURN TIMESTAMP(01234)
+----------------+
| timestamp(668) |
+----------------+
| 668 |
+----------------+
(root@nebula) [importer_test_v2]> RETURN TIMESTAMP(0o1234)
[ERROR (-1004)]: SyntaxError: syntax error near `o1234'
Thu, 01 Dec 2022 13:47:00 CST
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.
ACK.
@@ -17,6 +17,10 @@ import ( | |||
"gopkg.in/yaml.v2" | |||
) | |||
|
|||
var ( | |||
reTimestampInteger = regexp.MustCompile(`^(0[xX][0-9a-fA-F]+|0[0-7]+|\d+)$`) |
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.
ACK.
fix #229 |
fix: TIMESTAMP support integer
issue 229
What type of PR is this?
What problem(s) does this PR solve?
Issue(s) number:
Description:
How do you solve it?
Special notes for your reviewer, ex. impact of this fix, design document, etc: