MaxGekk commented on a change in pull request #24342: [SPARK-27438][SQL] Parse
strings with timestamps by to_timestamp() in microsecond precision
URL: https://github.com/apache/spark/pull/24342#discussion_r276195660
##########
File path:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/Cast.scala
##########
@@ -203,7 +203,11 @@ object Cast {
> SELECT _FUNC_('10' as int);
10
""")
-case class Cast(child: Expression, dataType: DataType, timeZoneId:
Option[String] = None)
+case class Cast(
+ child: Expression,
+ dataType: DataType,
+ timeZoneId: Option[String] = None,
+ timestampScaleFactor: Long = MICROS_PER_SECOND)
Review comment:
> For end users, ParseToTimestamp and Cast are 2 functions that are
unrelated, though internally ParseToTimestamp is implemented via Cast.
`ParseToTimestamp` has to behave the same as `Cast` when a pattern is not
provided.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]