zstan commented on code in PR #3558:
URL: https://github.com/apache/ignite-3/pull/3558#discussion_r1557340765
##########
modules/sql-engine/src/main/java/org/apache/ignite/internal/sql/engine/exec/exp/IgniteSqlFunctions.java:
##########
@@ -574,6 +575,75 @@ public static Long subtractTimeZoneOffset(long timestamp,
TimeZone timeZone) {
return timestamp - offset;
}
+ /**
+ * Helper for CAST({timestamp} AS VARCHAR(n)).
+ *
+ * <p>Note: this method is a copy of the avatica {@link
DateTimeUtils#unixTimestampToString(long, int)} method,
+ * with the only difference being that it does not add trailing
zeros.
+ */
+ public static String unixTimestampToString(long timestamp, int precision) {
Review Comment:
is it critical that we append trailing zeros ? or it made for consistency
between different temporal tests conversion ? what if we are using not
modifying functions ?
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]