Class ParameterUtil

java.lang.Object
io.trino.operator.scalar.json.ParameterUtil

public final class ParameterUtil extends Object
  • Method Details

    • getParametersArray

      public static Object[] getParametersArray(Type parametersRowType, SqlRow parametersRow)
      Converts the parameters passed to json path into appropriate values, respecting the proper SQL semantics for nulls in the context of a path parameter, and collects them in an array.

      All non-null values are passed as-is. Conversions apply in the following cases: - null value with FORMAT option is converted into an empty JSON sequence - null value without FORMAT option is converted into a JSON null.

      Parameters:
      parametersRowType - type of the Block containing parameters
      parametersRow - a row containing parameters
      Returns:
      an array containing the converted values