表分区的概念-Greenplum 数据库基础培训V1.2

时间:2021-04-25 21:28:08
【文件属性】:
文件名称:表分区的概念-Greenplum 数据库基础培训V1.2
文件大小:7.92MB
文件格式:PPT
更新时间:2021-04-25 21:28:08
Greenplum 中文 表分区的概念 将一张大表逻辑性地分成多个部分,如按照分区条件进行查询,将减少数据的扫描范围,提高系统性能。 提高对于特定类型数据的查询速度和性能 也可以更方便数据库的维护和更新 两种类型: Range分区 (日期范围或数字范围)/如日期、价格等 List 分区,例如地区、产品等 Greenplum中的表分区在使用中具有总表的继承性,并通过Check参数指定相应的子表 分区的子表依然根据分布策略分布在各segment上 分区是一种非常有用的优化措施,例如一年的交易按交易日期分区后,查询一天的交易性能将提高365倍!!! Instructor Notes Table partitioning addresses the problem of supporting very large tables, such as fact tables, by allowing you to divide them into smaller and more manageable pieces. The advantages of partitioning are to improve query performance by scanning only the relevant data needed to satisfy a given query. It can also be used to facilitate database maintenance tasks such as rolling old data out of the data warehouse or speeding up the update of indexes. GPDB supports both range partitioning (division of data based on a numerical range, such as date or price) or list partitioning (division of data based on a list of values, such as gender or region), or a combination of both types. Table partitioning in GPDB works using table inheritance and constraints. Table inheritance creates a persistent relationship between a child table and its parent table(s), so that all of the schema information from the parent table propagates to its children. CHECK constraints limit the data a table can contain based on some defining criteria. These constraints are also used at runtime to determine which tables to scan in order to satisfy a given query. In Greenplum DB partitioned tables are also distributed across the segments as is any non-partitioned table. Partitioning is more of a tool to logically divide big tables to improve query performance and maintenance. It does not effect the physical distribution of the table data.

网友评论