Amazon Redshift如何存储空值

问题描述 投票:1回答:1

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

我正在寻找如何最好地设计一个表 - 它背后的数据可能意味着它将有许多人口稀少的列,所以我想知道这是否会产生负面影响(即使在压缩后)或者如果没有实际上根本不占用任何空间(例如像mysql中的v5.0.3或更高版本)

谢谢

amazon-redshift
1个回答
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.
© www.soinside.com 2019 - 2024. All rights reserved.