AngersZhuuuu commented on pull request #32001: URL: https://github.com/apache/spark/pull/32001#issuecomment-810723338
> @AngersZhuuuu Any thoughts about use cases? @cloud-fan I could imagine the use cases when we need to transfer/save/load intervals to external systems that don't support any interval types natively. In that case, we can convert our intervals to int/long upload there, and maybe perform some arithmetic ops in the remote systems. If we look at the alternatives proposed by you: These two types have a standard value, such as microsecond. When there are standard values, this conversion could be safe. Such as DayTimeIntervalType, for this type, when store in InternalRow, the value is microsecond, then the conversion is safety. Compared with other string or `make_interval` function conversions, numeric conversion is more direct and easy to use when integrate with other system. We need to describe these content in detail in the document, such as the meaning of the stored value type, so that users can use it correctly when use `cast`. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
