Fintech ledger and balances
Model a double-entry ledger fact and a daily balance snapshot that share one conformed account dimension.
Concept
conformed-dimensions
The primary modeling idea this problem reinforces.
Requirements
3
Business needs the model must satisfy.
A fintech needs auditable balances and fast daily reporting. Balances must reconcile from a double-entry ledger, and dashboards need a daily balance per account without replaying the whole ledger.
Auditability comes from the ledger; reporting speed comes from the snapshot. Both must conform to one account dimension or the two views disagree.
- Add a ledger entry fact with an entry-type flag and a signed amount.
- Add a daily balance snapshot with a balance measure, snapshot date, and a key on account plus date.
- Connect both facts to the same account dimension by surrogate key.
Template
Fintech synthesis starter
The model users start from in the full workspace.
Entities
1
Seeded tables visible in the public preview.
Dialect
postgresql
Generated SQL target for this starter model.
This preview is read-only. Open the workspace to edit and verify; saving needs a free account.
Open workspaceTry the question first.
The discussion has other people's approaches and solutions. Give it a real attempt before you read them.