You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "linrrzqqq (via GitHub)" <gi...@apache.org> on 2025/10/09 12:16:16 UTC

[PR] [Feature](func) Support function EXPORT_SET [doris-website]

linrrzqqq opened a new pull request, #2952:
URL: https://github.com/apache/doris-website/pull/2952

   ## Versions 
   
   - [x] dev
   - [ ] 3.0
   - [ ] 2.1
   - [ ] 2.0
   
   ## Languages
   
   - [x] Chinese
   - [x] English
   
   ## Docs Checklist
   
   - [ ] Checked by AI
   - [ ] Test Cases Built
   


-- 
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-unsubscribe@doris.apache.org

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


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


Re: [PR] [Feature](func) Support function EXPORT_SET [doris-website]

Posted by "zclllyybb (via GitHub)" <gi...@apache.org>.
zclllyybb commented on code in PR #2952:
URL: https://github.com/apache/doris-website/pull/2952#discussion_r2422630738


##########
i18n/zh-CN/docusaurus-plugin-content-docs/current/sql-manual/sql-functions/scalar-functions/string-functions/export-set.md:
##########
@@ -0,0 +1,157 @@
+---
+{
+    "title": "EXPORT_SET",
+    "language": "zh-CN"
+}
+---
+
+## 描述
+
+`EXPORT_SET` 用于将一个整数的每一位(bit)转换为指定的字符串,并拼接成结果字符串。对于 `bits` 中每个为 1 的位,结果中对应位置会显示 `on` 字符串;每个为 0 的位则显示 `off` 字符串。位的检查顺序是从右到左(即从低位到高位),而拼接到结果字符串时是从左到右。各位之间通过 `separator` 分隔(默认为逗号`,`)。
+
+展示的位数由 `number_of_bits` 参数决定,默认展示 64 位。如果未指定或超出范围(大于 64)

Review Comment:
   似乎没说完?



##########
i18n/zh-CN/docusaurus-plugin-content-docs/current/sql-manual/sql-functions/scalar-functions/string-functions/export-set.md:
##########
@@ -0,0 +1,157 @@
+---
+{
+    "title": "EXPORT_SET",
+    "language": "zh-CN"
+}
+---
+
+## 描述
+
+`EXPORT_SET` 用于将一个整数的每一位(bit)转换为指定的字符串,并拼接成结果字符串。对于 `bits` 中每个为 1 的位,结果中对应位置会显示 `on` 字符串;每个为 0 的位则显示 `off` 字符串。位的检查顺序是从右到左(即从低位到高位),而拼接到结果字符串时是从左到右。各位之间通过 `separator` 分隔(默认为逗号`,`)。
+
+展示的位数由 `number_of_bits` 参数决定,默认展示 64 位。如果未指定或超出范围(大于 64)
+
+该函数行为与 [mysql](https://dev.mysql.com/doc/refman/8.4/en/string-functions.html#function_export-set) 一致。
+
+## 语法
+
+```sql
+EXPORT_SET(bits, on, off[, separator[, number_of_bits]])
+```
+
+## 参数
+
+| 参数              | 说明 |
+|-------------------|------|
+| `bits`            | 用于转换的整数值,支持 [-2^63, 2^64 - 1] 范围。若小于 -2^63 则按 -2^63 处理,若大于 2^64 - 1 则按 2^63 - 1 处理 |

Review Comment:
   参数都说明一下类型



-- 
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-unsubscribe@doris.apache.org

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


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


Re: [PR] [Feature](func) Support function EXPORT_SET [doris-website]

Posted by "zclllyybb (via GitHub)" <gi...@apache.org>.
zclllyybb merged PR #2952:
URL: https://github.com/apache/doris-website/pull/2952


-- 
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-unsubscribe@doris.apache.org

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


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