diff --git a/docs/src/rust/user-guide/expressions/lists.rs b/docs/src/rust/user-guide/expressions/lists.rs index 05b1b4f6f1f9..257649e0cc7d 100644 --- a/docs/src/rust/user-guide/expressions/lists.rs +++ b/docs/src/rust/user-guide/expressions/lists.rs @@ -21,7 +21,7 @@ fn main() -> Result<(), Box> { let out = weather .clone() .lazy() - .with_columns([col("temperatures").str().split(" ")]) + .with_columns([col("temperatures").str().split(lit(" "))]) .collect()?; println!("{}", &out); // --8<-- [end:string_to_list] @@ -30,7 +30,7 @@ fn main() -> Result<(), Box> { let out = weather .clone() .lazy() - .with_columns([col("temperatures").str().split(" ")]) + .with_columns([col("temperatures").str().split(lit(" "))]) .explode(["temperatures"]) .collect()?; println!("{}", &out); @@ -40,7 +40,7 @@ fn main() -> Result<(), Box> { let out = weather .clone() .lazy() - .with_columns([col("temperatures").str().split(" ")]) + .with_columns([col("temperatures").str().split(lit(" "))]) .with_columns([ col("temperatures").list().head(lit(3)).alias("top3"), col("temperatures") @@ -59,7 +59,7 @@ fn main() -> Result<(), Box> { .lazy() .with_columns([col("temperatures") .str() - .split(" ") + .split(lit(" ")) .list() .eval(col("").cast(DataType::Int64).is_null(), false) .list() @@ -75,7 +75,7 @@ fn main() -> Result<(), Box> { .lazy() .with_columns([col("temperatures") .str() - .split(" ") + .split(lit(" ")) .list() .eval(col("").str().contains(lit("(?i)[a-z]"), false), false) .list()