zclllyybb commented on code in PR #1955:
URL: https://github.com/apache/doris-website/pull/1955#discussion_r1945888730


##########
docs/sql-manual/sql-functions/scalar-functions/string-functions/compress.md:
##########
@@ -0,0 +1,67 @@
+---
+{
+    "title": "COMPRESS",
+    "language": "en"
+}
+---
+
+<!-- 
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+## Description
+The COMPRESS function is used to compress strings or values into binary data. 
The compressed data can be decompressed using the UNCOMPRESS function.
+
+## Syntax
+
+```sql
+COMPRESS(<uncompressed_str>)
+```
+
+## Parameters
+
+| Parameters                | Description            |
+|--------------------|---------------|
+| `<uncompressed_str>` | Uncompressed raw string |
+
+The parameter type is varchar or string
+
+## Return Value
+The return string is the same as the input <uncompressed_str> type  
+The first ten digits of the returned string are the hexadecimal length of the 
original string, for example, 0x01000000. What follows is the compressed byte 
stream, which is unreadable and you should not get it.
+
+Special case:
+- <uncompressed_str> Return '0x' when input is ''
+
+## Example
+
+``` sql
+select compress('abc');
+```
+The result of the decompression is unreadable and you don't need to care about 
its true value.

Review Comment:
   dont comment like this. add a example like uncompress(compress())



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to