Skip to content

Commit

Permalink
feat(spanner/spansql): fill in missing hash functions (#4808)
Browse files Browse the repository at this point in the history
The `spansql` package is quite useful for parsing and managing schemas,
however, with the addition of `CHECK` constraints to the spanner DDL,
the full set of SQL functions can now appear in schemas.

Fill in the missing Hash functions to support their use.

List of hash functions pulled from: https://cloud.google.com/spanner/docs/hash_functions
  • Loading branch information
dfinkel committed Sep 28, 2021
1 parent 4fc91cb commit 37ee2d9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions spanner/spansql/keywords.go
Expand Up @@ -152,7 +152,9 @@ var allFuncs = []string{
"ABS",

// Hash functions.
"FARM_FINGERPRINT",
"SHA1",
"SHA256", "SHA512",

// String functions.
"BYTE_LENGTH", "CHAR_LENGTH", "CHARACTER_LENGTH",
Expand Down

0 comments on commit 37ee2d9

Please sign in to comment.