mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-20 15:31:15 -05:00
Update created_at column of ft_billing to be non-nullable
`created_at` was added previously and made nullable temporarily. This commit now populates the column, ensures that it will always have a value, and makes `created_at` non-nullable.
This commit is contained in:
@@ -229,7 +229,8 @@ def update_fact_billing(data, process_day):
|
||||
stmt = stmt.on_conflict_do_update(
|
||||
constraint="ft_billing_pkey",
|
||||
set_={"notifications_sent": stmt.excluded.notifications_sent,
|
||||
"billable_units": stmt.excluded.billable_units
|
||||
"billable_units": stmt.excluded.billable_units,
|
||||
"updated_at": datetime.utcnow()
|
||||
}
|
||||
)
|
||||
db.session.connection().execute(stmt)
|
||||
|
||||
Reference in New Issue
Block a user