A SaaS workspace imports a batch of tasks. One row carries workspace 10 and project 202. Both IDs exist, so the database accepts the row. But project 202 belongs to workspace 20. The import has created a task whose recorded owner and parent disagree. Multi-tenant...
Two shoppers add the last pair of headphones to their carts. Both checkouts read available = 1 before either writes anything. If both accept the order based on that read, one customer gets a confirmation for stock you don’t have. Inventory reservation database design...
A team deletes a project called launch-plan, creates another project with the same name, and later restores the original. Which project gets the URL? Adding deleted_at to a table does not answer that question. Soft delete database design must define identity,...
A customer updates an order. Your application sends a webhook to three partner systems. Two respond successfully; the third times out. Five minutes later, support asks whether that partner received the update, what was sent, and whether retrying will create a...
How to Design a Database for Recurring Appointments and Schedule Exceptions A customer books a workshop every Wednesday at 9:00 AM. Three weeks later, the instructor moves one session to Thursday. The following week is canceled because the building is closed....
How to Design a Database for External Data Imports Without Losing Identity A company imports customer records from three systems. The CRM contains [email protected]. The billing platform contains [email protected]. An older marketplace export contains the same...
Recent Comments