TOPIC
Databases
These are the same questions found in the library, grouped here by the capability each one mainly examines.
69 questions
Questions 51–69 of 69 on this page.
A · Professional problem solving and implementation4
- The client sees one submission, but the server occasionally creates two identical records. It usually happens after a timeout and retry, with no obvious log error. How would you reconstruct the request timeline and verify where duplication occurs?
- A shared cache is read-heavy and the team plans to replace a mutex with a reader-writer lock. What evidence would you gather, and how would you judge whether the added complexity is worthwhile?
- A migration across millions of records cannot fit in one transaction. The business cannot expose a partially completed state. How would you design batched writes, visibility, and recovery?
- Database storage grows while cleanup scans cannot reclaim space; reporting transactions run for hours. How would you diagnose and govern this?
No questions in this section match your target. ·
B · Business understanding and domain modeling15
- A campaign allows each user to claim a discount once, but under high concurrency a user submits from multiple devices and receives several entitlements. How would you map the eligibility rule to atomic reservation, issuance records, and failure compensation?
- A database field has been replaced, but reports, exports, and external integrations still read it; deleting it directly could cause silent errors. How would you plan compatibility migration, consumer confirmation, and final removal?
- Customers pay by API usage, but usage events may be duplicated, arrive late, or be replayed at month-end; sent invoices can lead to disputes. How would you define billable units, deduplication keys, close windows, and corrections?
- Business reporting needs the duration of every state transition, while an operations page needs only the object's current state; a wide table overwrote history during updates. How would you separate event facts, snapshots, and current-state models?
- Several teams maintain customer profiles. When data is wrong, no one knows which system is authoritative, and systems also write values back to one another. How would you define field ownership, source of truth, synchronization direction, and dispute handling?
- A numeric feature value of zero may mean the user had no activity, missing may mean the device did not report, and unknown may mean computation is unfinished; the pipeline currently fills all three with zero. How would you define the semantics and downstream handling?
- An event producer wants to change a field from a string to a structured object, but some consumers deploy slowly and others drop unknown fields when writing records back. How would you stage dual writes, version negotiation, migration, and retirement of the old format?
- Orders contain nested line items, shipping, and tax, while refunds may apply to only some items; joining order headers directly to lines doubles totals in existing reports. How would you model grain and aggregation semantics?
- A new workflow requires every record to have an ownership field, but historical data lacks it and older clients still write records. How would you design backfill provenance, dual-read/write migration, validation gates, and retirement of old clients?
- An order is priced in one currency and paid in another; a refund occurs after the exchange rate changes, and line-item rounding leaves the total off by the smallest currency unit. How would you define rate timing, rounding order, and ownership of the difference?
- A customer entity must be split into two real customers after an erroneous merge, while old orders, permissions, and metrics reference the original ID. How would you model the split, historical attribution, current-reference migration, and indeterminate records?
- Operations counts revenue when an order is placed, while finance recognizes it after fulfillment and refunds. A leader wants one number. How would you explain the two measurement methods and design shared measures for decisions?
- Orders, inventory, and loyalty points are owned by separate services; messages may be duplicated, reordered, or delayed. How would you define event identity, idempotency boundaries, and compensation records?
- Several teams manually corrected an aggregate table, and later no one could explain why the number changed. How would you record sources, transformations, versions, owners, and recomputation evidence?
- A product line splits into two business units. Old orders belong to the previous organization, while future orders use the new structure. How would you represent organization versions and historical views?
No questions in this section match your target. ·