This is an automated email from the ASF dual-hosted git repository.
jonah pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/datafusion.git
The following commit(s) were added to refs/heads/main by this push:
new 7ebd993fe4 Fix `scalar_functions.md` for CI (#13340)
7ebd993fe4 is described below
commit 7ebd993fe47e78006bad33256160716f73b13cef
Author: Jax Liu <[email protected]>
AuthorDate: Sun Nov 10 22:25:49 2024 +0800
Fix `scalar_functions.md` for CI (#13340)
* fix format of document ci
* remove the indent of mpa example
---
datafusion/functions-nested/src/map.rs | 55 +++++++++++++++++-----------------
1 file changed, 28 insertions(+), 27 deletions(-)
diff --git a/datafusion/functions-nested/src/map.rs
b/datafusion/functions-nested/src/map.rs
index cad193910c..73aad10a8e 100644
--- a/datafusion/functions-nested/src/map.rs
+++ b/datafusion/functions-nested/src/map.rs
@@ -261,33 +261,34 @@ fn get_map_doc() -> &'static Documentation {
"map(key, value)\nmap(key: value)\nmake_map(['key1',
'key2'], ['value1', 'value2'])"
)
.with_sql_example(
- r#"```sql
- -- Using map function
- SELECT MAP('type', 'test');
- ----
- {type: test}
-
- SELECT MAP(['POST', 'HEAD', 'PATCH'], [41, 33, null]);
- ----
- {POST: 41, HEAD: 33, PATCH: }
-
- SELECT MAP([[1,2], [3,4]], ['a', 'b']);
- ----
- {[1, 2]: a, [3, 4]: b}
-
- SELECT MAP { 'a': 1, 'b': 2 };
- ----
- {a: 1, b: 2}
-
- -- Using make_map function
- SELECT MAKE_MAP(['POST', 'HEAD'], [41, 33]);
- ----
- {POST: 41, HEAD: 33}
-
- SELECT MAKE_MAP(['key1', 'key2'], ['value1', null]);
- ----
- {key1: value1, key2: }
- ```"#
+ r#"
+```sql
+-- Using map function
+SELECT MAP('type', 'test');
+----
+{type: test}
+
+SELECT MAP(['POST', 'HEAD', 'PATCH'], [41, 33, null]);
+----
+{POST: 41, HEAD: 33, PATCH: }
+
+SELECT MAP([[1,2], [3,4]], ['a', 'b']);
+----
+{[1, 2]: a, [3, 4]: b}
+
+SELECT MAP { 'a': 1, 'b': 2 };
+----
+{a: 1, b: 2}
+
+-- Using make_map function
+SELECT MAKE_MAP(['POST', 'HEAD'], [41, 33]);
+----
+{POST: 41, HEAD: 33}
+
+SELECT MAKE_MAP(['key1', 'key2'], ['value1', null]);
+----
+{key1: value1, key2: }
+```"#,
)
.with_argument(
"key",
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]