From 60b6afc62996bbbfeedbd5615e4d7a47330470c0 Mon Sep 17 00:00:00 2001 From: listar Date: Thu, 19 Aug 2021 10:03:44 +0000 Subject: [PATCH] 1. modify doc to add sha512 --- docs/en/sql-reference/functions/hash-functions.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/en/sql-reference/functions/hash-functions.md b/docs/en/sql-reference/functions/hash-functions.md index 35a42c49a41..227e2885417 100644 --- a/docs/en/sql-reference/functions/hash-functions.md +++ b/docs/en/sql-reference/functions/hash-functions.md @@ -143,7 +143,9 @@ It works faster than intHash32. Average quality. ## SHA256 {#sha256} -Calculates SHA-1, SHA-224, or SHA-256 from a string and returns the resulting set of bytes as FixedString(20), FixedString(28), or FixedString(32). +## SHA512 {#sha512} + +Calculates SHA-1, SHA-224, SHA-256 or SHA-512 from a string and returns the resulting set of bytes as FixedString(20), FixedString(28), FixedString(32), or FixedString(64). The function works fairly slowly (SHA-1 processes about 5 million short strings per second per processor core, while SHA-224 and SHA-256 process about 2.2 million). We recommend using this function only in cases when you need a specific hash function and you can’t select it. Even in these cases, we recommend applying the function offline and pre-calculating values when inserting them into the table, instead of applying it in SELECTS.