Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

fix: UpsertDBSchema updated_ts (#11608)

p0ny597f39e5240e
diff --git a/backend/store/db_schema.go b/backend/store/db_schema.go
index 04504377e5..d67db97693 100644
--- a/backend/store/db_schema.go
+++ b/backend/store/db_schema.go
@@ -84,7 +84,8 @@ func (s *Store) UpsertDBSchema(ctx context.Context, databaseID int, dbSchema *mo
VALUES ($1, $2, $3, $4, $5)
ON CONFLICT(database_id) DO UPDATE SET
metadata = EXCLUDED.metadata,
- raw_dump = EXCLUDED.raw_dump
+ raw_dump = EXCLUDED.raw_dump,
+ updated_ts = extract(epoch from now())
RETURNING metadata, raw_dump, config
`
tx, err := s.db.BeginTx(ctx, nil)