Skip to main content

list_values_row_number

Function list_values_row_number 

Source
pub fn list_values_row_number(array: &dyn Array) -> Result<ArrayRef>
Expand description

If array is a list or a map, returns a new array of the same length as it’s inner values where each value is the 1-based index of the sublist it’s contained. Example:

[[1], [2, 3], [4, 5, 6]] => [1, 2, 2, 3, 3, 3]

Otherwise returns an error