Skip to content

Commit

Permalink
SNOW-1271212 fixed test for lost nanos precision in conversion after …
Browse files Browse the repository at this point in the history
…epoch defined as Utc
  • Loading branch information
sfc-gh-mhofman committed Apr 3, 2024
1 parent adf3c45 commit 911182f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Snowflake.Data/Core/SFBindUploader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ internal string GetCSVData(string sType, string sValue)
int timeZoneOffset = int.Parse(tstzString[1]) - 1440; // SFDateConverter provides in minutes increased by 1440m
DateTime timestamp = epoch.AddTicks(nsFromEpochTz/100).AddMinutes(timeZoneOffset);
TimeSpan offset = TimeSpan.FromMinutes(timeZoneOffset);
DateTimeOffset tzDateTimeOffset = new DateTimeOffset(timestamp.Year, timestamp.Month, timestamp.Day, timestamp.Hour, timestamp.Minute, timestamp.Second, timestamp.Millisecond, offset);
DateTimeOffset tzDateTimeOffset = new DateTimeOffset(timestamp.Ticks, offset);
return tzDateTimeOffset.ToString("yyyy-MM-dd HH:mm:ss.fffffff zzz");
}
return sValue;
Expand Down

0 comments on commit 911182f

Please sign in to comment.