Re: Spark types implicit conversion to string

2021-11-10 Thread Sean Owen
I don't think I'd expect an automatic conversion from a complex type like Map to anything - implicit casts for primitive types are on the other hand relatively common. On Wed, Nov 10, 2021 at 6:01 PM Dhiren wrote: > Hi Spark Users, > I am trying to understand Spark’s type system a little better.

Spark types implicit conversion to string

2021-11-10 Thread Dhiren
Hi Spark Users, I am trying to understand Spark’s type system a little better. I see that Spark implicitly casts some types to String and not for others. Here is an example. df = spark.createDataFrame([({"test": 1.0}, 2.0, 3.0, 4.0)], ("observed", "expected", "obs_wt