HyukjinKwon commented on code in PR #37652:
URL: https://github.com/apache/spark/pull/37652#discussion_r954489472
##########
sql/core/src/main/scala/org/apache/spark/sql/functions.scala:
##########
@@ -3958,6 +3958,26 @@ object functions {
ElementAt(column.expr, lit(value).expr)
}
+ /**
+ * Returns element of array at given (0-based) index. If the index points
+ * outside of the array boundaries, then this function returns NULL.
+ *
+ * @group collection_funcs
+ * @since 3.4.0
+ */
+ def get(column: Column, index: Column): Column = withExpr {
+ new Get(column.expr, index.expr)
+ }
+
+ /**
+ * Returns element of array at given (0-based) index. If the index points
+ * outside of the array boundaries, then this function returns NULL.
+ *
+ * @group collection_funcs
+ * @since 3.4.0
+ */
+ def get(column: Column, index: Int): Column = get(column, lit(index))
Review Comment:
Let's probably don't add this (see the comments on the top of this file)
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]