2016-08-23 39 views
2

在Amazon Redshift中,空值如何存储? - 他们会占用实体空间吗?Amazon Redshift如何存储空值

我期待看到如何最好地设计一个表格 - 它背后的数据可能意味着它会有许多列是稀疏的人口,所以我想知道这是否有负面影响(即使在压缩后)或者,如果零点不实际(比如在MySQL中像v5.0.3或更高版本)占用任何空间都

谢谢

回答

2

是的,有很多空值的列将提供优良的压缩,因此大在Amazon Redshift上的表现。

Amazon Redshift is a columnar database engine. Columnar database are greatly optimized for data with repeating values, and those can be null.

所以,如果你有一个表,其中某些列有很多空的,这将很可能压缩得非常好,并提供存储节省以及处理速度。

为了实现适当的压缩,你有两个选择:

  1. DDL Design - Manually choose your encoding settings.
  2. Automatic - Have the copy command automatically choose the optimal encoding settings for your database.