Try to stabilize test, pt. II

This commit is contained in:
Robert Schulze 2023-10-26 19:41:29 +00:00
parent 0770744032
commit b1fd28d0f4
No known key found for this signature in database
GPG Key ID: 26703B55FB13728A
2 changed files with 10 additions and 8 deletions

View File

@ -3,4 +3,5 @@
2021-08-15 18:57:56.492 1426860704886947840 1426860704886947840
-- different DateTime64 scales
1426981498778550272 1426981500456271872 1426981500833759232 1426981500842147840 1426981500842147840
1 1 1 1 0
1 1 1 1
2023-11-11 11:11:11.1231 2023-11-11 11:11:11.123

View File

@ -35,10 +35,11 @@ SELECT dateTime64ToSnowflake(dt64_0),
WITH now64(0, 'UTC') AS dt64_0,
now64(1, 'UTC') AS dt64_1,
now64(2, 'UTC') AS dt64_2,
now64(3, 'UTC') AS dt64_3,
now64(4, 'UTC') AS dt64_4
SELECT snowflakeToDateTime64(dateTime64ToSnowflake(dt64_0)) == dt64_0,
snowflakeToDateTime64(dateTime64ToSnowflake(dt64_1)) == dt64_1,
snowflakeToDateTime64(dateTime64ToSnowflake(dt64_2)) == dt64_2,
snowflakeToDateTime64(dateTime64ToSnowflake(dt64_3)) == dt64_3,
snowflakeToDateTime64(dateTime64ToSnowflake(dt64_4)) == dt64_4;
now64(3, 'UTC') AS dt64_3
SELECT snowflakeToDateTime64(dateTime64ToSnowflake(dt64_0), 'UTC') == dt64_0,
snowflakeToDateTime64(dateTime64ToSnowflake(dt64_1), 'UTC') == dt64_1,
snowflakeToDateTime64(dateTime64ToSnowflake(dt64_2), 'UTC') == dt64_2,
snowflakeToDateTime64(dateTime64ToSnowflake(dt64_3), 'UTC') == dt64_3;
WITH toDateTime64('2023-11-11 11:11:11.1231', 4, 'UTC') AS dt64_4
SELECT dt64_4, snowflakeToDateTime64(dateTime64ToSnowflake(dt64_4), 'UTC'); -- not idempotent