二: Normalize if you need to future-proof data

2: Normalize if you need to future-proof data

原文如下:

 

Normalization “future-proofs” your data: you should be able to use normalized data
for different applications that will query the data in different ways in the future.
This assumes that you have some data set that application after application, for years
and years, will have to use. There are data sets like this, but most people’s data is
constantly evolving, and old data is either updated or drops by the wayside. Most people
want their database performing as fast as possible on the queries they’re doing now,
and if they change those queries in the future, they’ll optimize their database for the
new queries.
Also, if an application is successful, its data set often becomes very application-specific.
That isn’t to say it couldn’t be used for more that one application; often you’ll at least
want to do meta-analysis on it. But this is hardly the same as “future-proofing” it to
stand up to whatever queries people want to run in 10 years.
   举个例子以后订单数据还需要用在其他应用中,商品数据也需要用在其他应用中,这些新数据的查询方式也按照特定应用来优化,这时如果把商品与订单数据放在一起,那么以后的修改删除什么的,需要操作好几份数据,这样为了保证数据一致,反而牺牲了太多的性能,所以如果在设计scheme时考虑到以后的数据应用,就应该按照正常的范式来。