Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit945f224

Browse files
committed
update README.md
1 parentbc504d4 commit945f224

File tree

1 file changed

+12
-9
lines changed

1 file changed

+12
-9
lines changed

‎README.md‎

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,27 @@ The extension is compatible with:
1212
* Postgres Pro Standard 9.5, 9.6;
1313
* Postgres Pro Enterprise;
1414

15-
By the way, we have a growing Wiki[out there](https://github.com/postgrespro/pg_pathman/wiki).
15+
Take a look at our Wiki[out there](https://github.com/postgrespro/pg_pathman/wiki).
1616

1717
##Overview
18-
**Partitioning** means splitting one large table into smaller pieces. Each row in such table is moved to a single partition according to the partitioning key. PostgreSQL supports partitioning via table inheritance: each partition must be created as a child table with CHECK CONSTRAINT. For example:
18+
**Partitioning** means splitting one large table into smaller pieces. Each row in such table is moved to a single partition according to the partitioning key. PostgreSQL<= 10supports partitioning via table inheritance: each partition must be created as a child table with CHECK CONSTRAINT:
1919

2020
```plpgsql
2121
CREATETABLEtest (idSERIALPRIMARY KEY, titleTEXT);
2222
CREATETABLEtest_1 (CHECK ( id>=100AND id<200 )) INHERITS (test);
2323
CREATETABLEtest_2 (CHECK ( id>=200AND id<300 )) INHERITS (test);
2424
```
2525

26+
PostgreSQL 10 provides native partitioning:
27+
28+
```plpgsql
29+
CREATETABLEtest(id int4, valuetext) PARTITION BY RANGE(id);
30+
CREATETABLEtest_1 PARTITION OF test FORVALUESFROM (1) TO (10);
31+
CREATETABLEtest_2 PARTITION OF test FORVALUESFROM (10) TO (20);
32+
```
33+
34+
It's not so different from the classic approach; there are implicit check constraints, and most of its limitations are still relevant.
35+
2636
Despite the flexibility, this approach forces the planner to perform an exhaustive search and to check constraints on each partition to determine whether it should be present in the plan or not. Large amount of partitions may result in significant planning overhead.
2737

2838
The`pg_pathman` module features partition managing functions and optimized planning mechanism which utilizes knowledge of the partitions' structure. It stores partitioning configuration in the`pathman_config` table; each row contains a single entry for a partitioned table (relation name, partitioning column and its type). During the initialization stage the`pg_pathman` module caches some information about child partitions in the shared memory, which is used later for plan construction. Before a SELECT query is executed,`pg_pathman` traverses the condition tree in search of expressions like:
@@ -60,13 +70,6 @@ More interesting features are yet to come. Stay tuned!
6070
* FDW support (foreign partitions);
6171
* Various GUC toggles and configurable settings.
6272

63-
##Roadmap
64-
65-
* Multi-level partitioning (ver 1.5);
66-
* Improved referential integrity + foreign keys on partitioned tables (ver 1.5);
67-
68-
Take a look at[this page](https://github.com/postgrespro/pg_pathman/wiki/Roadmap);
69-
7073
##Installation guide
7174
To install`pg_pathman`, execute this in the module's directory:
7275
```shell

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp