4 ms·
Absolutely. Take the example of eCommerce. I tend to categorize eCom data into three units. Definitions, Transactions, State. Definitions : Data that describe
by kumarvvr 5y ago
Absolutely.
Take the example of eCommerce. I tend to categorize eCom data into three units. Definitions, Transactions, State.
Definitions : Data that describe products, brands, categories, customers, vendors, etc. This has incredible variation and constantly evolving, with perhaps some core tenets being common across different business use cases.
Transactions : These are your sales, purchases, discounts, returns, etc. Not too much variation, more or less similar across various business verticals.
State : Inventory, stores, location of goods, etc. Least variance, can be referenced to Definitions and Transactions. Operations are standard and mostly fixed.
Choosing a PostgreSQL database, allows me to model Definitions as collections of JSONB items, with a few columns for id, time stamps, etc.
Transactions and state are best modeled as relational tables, with references to definitions.
- raihansaputra 5y agoHow does the app code deal with the State/Transaction data? I assume the State/Transaction data will have columns that will comply with a Definition? How does the State/Transaction change after a Definition is changed?
- kumarvvr 5y agoState is referenced to object id, state changes are stored as ledger entries, transactions are also ledger entries. All are referenced to object ids only.