!2662 修复升级hdfs_fdw创建失败问题

Merge pull request !2662 from 杨皓/master
This commit is contained in:
opengauss-bot
2022-12-21 06:15:11 +00:00
committed by Gitee
4 changed files with 10 additions and 6 deletions

View File

@ -125,7 +125,7 @@ BEGIN
IF ans = false then
select case when count(*)=1 then true else false end as has_version_proc from (select * from pg_proc where proname = 'working_version_num' limit 1) into has_version_proc;
IF has_version_proc = true then
select working_version_num < 92626 as old_version from working_version_num() into old_version;
select working_version_num < 92608 as old_version from working_version_num() into old_version;
IF old_version = true then
raise info 'Processing hdfs extension';
query_str := 'CREATE EXTENSION IF NOT EXISTS hdfs_fdw;';
@ -135,4 +135,4 @@ BEGIN
END IF;
END LOOP;
END
$do$;
$do$;

View File

@ -125,7 +125,7 @@ BEGIN
IF ans = false then
select case when count(*)=1 then true else false end as has_version_proc from (select * from pg_proc where proname = 'working_version_num' limit 1) into has_version_proc;
IF has_version_proc = true then
select working_version_num < 92626 as old_version from working_version_num() into old_version;
select working_version_num < 92608 as old_version from working_version_num() into old_version;
IF old_version = true then
raise info 'Processing hdfs extension';
query_str := 'CREATE EXTENSION IF NOT EXISTS hdfs_fdw;';
@ -135,4 +135,4 @@ BEGIN
END IF;
END LOOP;
END
$do$;
$do$;

View File

@ -56,4 +56,6 @@ CREATE OR REPLACE FUNCTION pg_catalog.gs_undo_dump_parsepage_mv(relpath text, bl
LANGUAGE internal
STABLE STRICT NOT FENCED NOT SHIPPABLE
AS $function$gs_undo_dump_parsepage_mv$function$;
comment on function PG_CATALOG.gs_undo_dump_parsepage_mv(relpath text, blkno bigint, reltype text, rmem boolean) is 'parse uheap data page and undo to output file based on given filepath';
comment on function PG_CATALOG.gs_undo_dump_parsepage_mv(relpath text, blkno bigint, reltype text, rmem boolean) is 'parse uheap data page and undo to output file based on given filepath';
DROP EXTENSION IF EXISTS hdfs_fdw;

View File

@ -56,4 +56,6 @@ CREATE OR REPLACE FUNCTION pg_catalog.gs_undo_dump_parsepage_mv(relpath text, bl
LANGUAGE internal
STABLE STRICT NOT FENCED NOT SHIPPABLE
AS $function$gs_undo_dump_parsepage_mv$function$;
comment on function PG_CATALOG.gs_undo_dump_parsepage_mv(relpath text, blkno bigint, reltype text, rmem boolean) is 'parse uheap data page and undo to output file based on given filepath';
comment on function PG_CATALOG.gs_undo_dump_parsepage_mv(relpath text, blkno bigint, reltype text, rmem boolean) is 'parse uheap data page and undo to output file based on given filepath';
DROP EXTENSION IF EXISTS hdfs_fdw;