10 ms·
> Isn't upsert a bad design smell though? It depends. We use upserts for certain kinds of data in LedgerSMB despite the fact that a lot of data is append-only
by einhverfr 13y ago
> Isn't upsert a bad design smell though?
It depends. We use upserts for certain kinds of data in LedgerSMB despite the fact that a lot of data is append-only.
> If you have high concurrent updates, you should be dealing with append-only database design and collapsing into a view to query, like Datomic. All the locking required for atomic upserts would wreak havoc on performance anyway no?
There are many cases beyond high concurrent updates where you want an append-only design. We use a lot of append-only in LedgerSMB but that's for transparency/audit control reasons.
The problem is handling corner cases with upserts. The fact is that it is a useful tool in many areas. However you wouldn't use a chasing hammer to drive nails, would you?