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

[SQL] Support MySQL SHA1 & SHA function. #500

Closed
Tracked by #454
dongzl opened this issue Nov 10, 2022 · 0 comments · Fixed by #510
Closed
Tracked by #454

[SQL] Support MySQL SHA1 & SHA function. #500

dongzl opened this issue Nov 10, 2022 · 0 comments · Fixed by #510
Assignees
Labels
SQL SQL support
Milestone

Comments

@dongzl
Copy link
Contributor

dongzl commented Nov 10, 2022

What would you like to be added:

Why is this needed:

ref #454

official document:
https://dev.mysql.com/doc/refman/5.6/en/encryption-functions.html#function_sha1

code:
https://github.com/arana-db/arana/tree/master/pkg/runtime/function/scripts/crypto.js

reference code:

https://github.com/arana-db/arana/tree/master/pkg/runtime/function2/abs.go

need register twice.

func init() {
   proto.RegisterFunc("SHA", shaFunc{})
   proto.RegisterFunc("SHA1", shaFunc{})
}
@dongzl dongzl mentioned this issue Nov 10, 2022
43 tasks
@dongzl dongzl added the SQL SQL support label Nov 10, 2022
@dongzl dongzl added this to the 0.2.0 milestone Nov 10, 2022
@dongzl dongzl changed the title SHA [SQL] Support MySQL SHA1 function. Nov 10, 2022
@dongzl dongzl changed the title [SQL] Support MySQL SHA1 function. [SQL] Support MySQL SHA1 & SHA function. Nov 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
SQL SQL support
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants