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

Commitdebe43d

Browse files
committed
Forbid to partition tables with children.
Since pathman doesn't check for children existence anyway and duplicatesthem. This doesn't explain 'attempted to update invisible tuple' in PGPRO-2507though, but let's leave this for another time.
1 parent0299398 commitdebe43d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

‎init.sql

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -455,6 +455,10 @@ BEGIN
455455
RAISE EXCEPTION'table "%" has already been partitioned', parent_relid;
456456
END IF;
457457

458+
IF EXISTS (SELECT1FROM pg_inheritsWHERE inhparent= parent_relid) THEN
459+
RAISE EXCEPTION'can''t partition table "%" with existing children', parent_relid;
460+
END IF;
461+
458462
/* Check if there are foreign keys that reference the relation*/
459463
FOR constr_nameIN (SELECT connameFROMpg_catalog.pg_constraint
460464
WHERE confrelid= parent_relid::REGCLASS::OID)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp