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

Commitdbd786b

Browse files
committed
pg_upgrade: avoid ALTER COLUMN TYPE on inherited columns
This only affects upgrades from 8.3 currently, and is harmless as thechild just generates an error in the script, but we should get it rightin case we ever need this for more complex uses.Per report from Peter Eisentraut
1 parentb1543cc commitdbd786b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

‎contrib/pg_upgrade/version_old_8_3.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,6 +325,8 @@ old_8_3_rebuild_tsvector_tables(ClusterInfo *cluster, bool check_mode)
325325
"WHEREc.relkind = 'r' AND "
326326
"c.oid = a.attrelid AND "
327327
"NOT a.attisdropped AND "
328+
/* child attribute changes are processed by the parent */
329+
"a.attinhcount = 0 AND "
328330
"a.atttypid = 'pg_catalog.tsvector'::pg_catalog.regtype AND "
329331
"c.relnamespace = n.oid AND "
330332
/* exclude possible orphaned temp tables */
@@ -346,6 +348,8 @@ old_8_3_rebuild_tsvector_tables(ClusterInfo *cluster, bool check_mode)
346348
"WHEREc.relkind = 'r' AND "\
347349
"c.oid = a.attrelid AND "\
348350
"NOT a.attisdropped AND "\
351+
/* child attribute changes are processed by the parent */\
352+
"a.attinhcount = 0 AND "\
349353
"a.atttypid = 'pg_catalog.tsvector'::pg_catalog.regtype AND " \
350354
"c.relnamespace = n.oid AND "\
351355
" n.nspname !~ '^pg_' AND "\

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp