MartijnVisser commented on code in PR #30200: URL: https://github.com/apache/flink/pull/30200#discussion_r4772844984
########## docs/data/functions/string-and-binary/elt.yml: ########## @@ -0,0 +1,96 @@ +# 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 + +name: ELT +summary: Returns the expression at a given position in a list of expressions. + +syntax: + sql: ELT(n, expr1 [, expr2]*) + java: $("n").elt(expr1, expr2, ...) + python: col("n").elt(expr1, expr2, ...) + +arguments: + - name: "n" + type: INT + required: true + description: The position of the expression to return, 1 for `expr1`. + - name: expr1, expr2, ... + type: Character strings, or binary strings + required: true + description: The expressions to choose from. Either all of them are character strings, or all are binary strings. + +returns: + description: The expression at position `n` of the list. + nulls: Returns NULL if `n` is NULL, below 1 or greater than the number of expressions, or if the chosen expression is NULL. + type: The common type of the expressions, nullable. + +notes: + - A `TINYINT`, `SMALLINT` or `BIGINT` `n` fails the query when it is between 1 and the number of expressions. Cast it to `INT` first. Review Comment: #28931 for FLINK-40338 is approved and makes these index types work. Whichever of the two lands second needs to update this note and the `INT` type above. ########## docs/data/functions/string-and-binary/ascii.yml: ########## @@ -0,0 +1,83 @@ +# 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 + + +name: ASCII +summary: Returns the ASCII code of the first character of a string. Review Comment: For `é` the note below gives `-61`, which isn't an ASCII code. Please say in the summary that the result is only the code for an ASCII character. -- 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]
