fix(sqltypes): serialize SqlTimeStamp as RFC3339

Marshal JSON/YAML/XML and driver Value now emit time.RFC3339 instead of
the offset-less "2006-01-02T15:04:05" layout; zero-time guards compare
against the RFC3339 zero value. Parsing is unchanged and still accepts
bare datetimes.
This commit is contained in:
warkanum committed 2026-09-03 22:12:36 +02:00
1 parent 7031ffd262
commit d8e8d1a3a5
3 files changed
+10 -10

No files matched your search

+1 -1
View File
@@ -178,7 +178,7 @@ func TestSqlTimeStamp_JSON(t *testing.T) {
if err != nil {
t.Fatalf("Marshal failed: %v", err)
}
expected := `"2024-01-15T10:30:45"`
expected := `"2024-01-15T10:30:45Z"`
if string(data) != expected {
t.Errorf("expected %s, got %s", expected, string(data))
}