Hacker News new | ask | show | jobs
by BikiniPrince 1709 days ago
Yes, views are nice, but there is also a fair concept of not needlessly bogging down a table. Sure, they were making up data, but a flat table with stats, profile data and other easily external data is just bloat. Once you have an id then static fields can be retrieved from other services/data stores.
1 comments

I'm not sure I am following. Aren't materialized views just formal, cached results of a query? That wouldn't bog down a table.
I think their point is more ‘don’t store all that junk in your primary database and then do all your work on it there too if you can just stuff it somewhere else’. Which has pros and cons and depends a lot on various scaling factors.
Materialized views are persistent tables that are typically updated when the underlying data is updated.

Typically.

I'm pretty sure most engines use the term "materialized views" for eventual consistency tables. The only db I've seen with that kind of ACID materialized view is MS SQL, which calls them "indexed views".
Perhaps he means it will bog down on refresh.
Maybe? Not sure.