You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a component with id component-1 and 2 inventories with id inventory-1 and inventory-2
when I delete both of them, the package generates the following query:
UPDATE components SET quantity=(SELECTsum(inventories.quantity) AS sum_1
FROM inventories
WHEREcomponents.id=inventories.component_id), updated_at=now() WHEREcomponents.idIN ('component-1')
This query results on trying to set null in the quantity column because there are no inventories that match the where clause
Couldn't find anything in the documentation regarding this or open issue about this issue.
Using:
python 3.10
SQLAlchemy 2
sqlalchemy-utils 0.41.1
The text was updated successfully, but these errors were encountered:
I have two ORM models:
There is a one to many relationship between Component to Inventory
Component has a custom aggregated column named quantity defined as
I have a component with id
component-1
and 2 inventories with idinventory-1
andinventory-2
when I delete both of them, the package generates the following query:
This query results on trying to set null in the quantity column because there are no inventories that match the where clause
Couldn't find anything in the documentation regarding this or open issue about this issue.
Using:
The text was updated successfully, but these errors were encountered: