Github user maropu commented on a diff in the pull request:
https://github.com/apache/spark/pull/20176#discussion_r160310736
--- Diff:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/Cast.scala
---
@@ -732,6 +755,39 @@ case class Cast(child: Expression, dataType: DataType,
timeZoneId: Option[String
""".stripMargin
}
+ private def writeStructToStringBuilder(
+ st: Seq[DataType],
+ row: String,
+ buffer: String,
+ ctx: CodegenContext): String = {
+ val structToStringCode = st.zipWithIndex.map { case (ft, i) =>
+ val fieldToStringCode = castToStringCode(ft, ctx)
+ val funcName = ctx.freshName("fieldToString")
+ ctx.addNewFunction(funcName,
--- End diff --
ok, l'll update soon
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]