RangePartitionId Unary Expression¶
RangePartitionId is a UnaryExpression (Spark SQL) that represents range_partition_id function in a logical query plan (until it is resolved into PartitionerExpr by RangePartitionIdRewrite optimization).
Creating Instance¶
RangePartitionId takes the following to be created:
- Child
Expression(Spark SQL) - Number of partitions
RangePartitionId requires the number of partitions to be greater than 0.
RangePartitionId is created when:
- range_partition_id function is used
Unevaluable¶
RangePartitionId is Unevaluable (Spark SQL) that is rewritten by RangePartitionIdRewrite to PartitionerExpr.
checkInputDataTypes¶
checkInputDataTypes(): TypeCheckResult
checkInputDataTypes is part of the Expression (Spark SQL) abstraction.
checkInputDataTypes is successful when the DataType (Spark SQL) of the child expression is row-orderable (Spark SQL). Otherwise, checkInputDataTypes is negative.
Evaluation Result DataType¶
dataType: DataType
dataType is part of the Expression (Spark SQL) abstraction.
dataType is always IntegerType.
nullable¶
nullable: Boolean
nullable is part of the Expression (Spark SQL) abstraction.
nullable is always false.