Skip to content

fix: MsSQL timezone-safe timestamp normalization via AT TIME ZONE#51

Merged
dtsong merged 2 commits intomasterfrom
fix/30-mssql-timezone-normalization
Mar 30, 2026
Merged

fix: MsSQL timezone-safe timestamp normalization via AT TIME ZONE#51
dtsong merged 2 commits intomasterfrom
fix/30-mssql-timezone-normalization

Conversation

@dtsong
Copy link
Copy Markdown
Owner

@dtsong dtsong commented Mar 30, 2026

Summary

  • Wrap MsSQL normalize_timestamp() with explicit UTC conversion
  • Uses CAST(value AS DATETIMEOFFSET) AT TIME ZONE 'UTC' before formatting
  • MsSQL cannot set session timezone, so this normalizes explicitly in SQL

Key Files

  • data_diff/databases/mssql.pynormalize_timestamp() now converts to UTC

Test plan

  • Unit tests pass (55/55)
  • Ruff lint and format pass
  • MsSQL timestamp normalization produces UTC-consistent output

Closes #30

🤖 Generated with Claude Code

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix: MsSQL timezone-safe timestamp normalization via AT TIME ZONE

1 participant