robin-sparkless 4.4.0

PySpark-like DataFrame API in Rust on Polars; no JVM.
Documentation
{
  "name": "split_part",
  "pyspark_version": "3.5.0",
  "input": {
    "schema": [
      {
        "name": "id",
        "type": "bigint"
      },
      {
        "name": "a",
        "type": "string"
      }
    ],
    "rows": [
      [
        1,
        "11.12.13"
      ],
      [
        2,
        "a-b-c"
      ],
      [
        3,
        "one"
      ]
    ]
  },
  "operations": [
    {
      "op": "withColumn",
      "column": "r",
      "expr": "split_part(col('a'), '.', 3)"
    },
    {
      "op": "withColumn",
      "column": "r2",
      "expr": "split_part(col('a'), '-', 2)"
    }
  ],
  "expected": {
    "schema": [
      {
        "name": "id",
        "type": "bigint"
      },
      {
        "name": "a",
        "type": "string"
      },
      {
        "name": "r",
        "type": "string"
      },
      {
        "name": "r2",
        "type": "string"
      }
    ],
    "rows": [
      [
        1,
        "11.12.13",
        "13",
        ""
      ],
      [
        2,
        "a-b-c",
        "",
        "b"
      ],
      [
        3,
        "one",
        "",
        ""
      ]
    ]
  }
}