From 8264b16f429ed1391f6ef9b2fb2033f72e0907f2 Mon Sep 17 00:00:00 2001 From: wangfeihuo Date: Thu, 14 Nov 2024 18:43:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Dsum(int)=E6=80=A7=E8=83=BD?= =?UTF-8?q?=E8=BE=83=E5=B7=AE=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CMakeLists.txt | 6 ++++++ build/script/aarch64_finance_list | 2 ++ build/script/aarch64_lite_list | 2 ++ build/script/aarch64_opengauss_list | 2 ++ build/script/opengauss_release_list_ubuntu_single | 2 ++ build/script/x86_64_finance_list | 2 ++ build/script/x86_64_lite_list | 2 ++ build/script/x86_64_opengauss_list | 2 ++ src/common/backend/utils/init/globals.cpp | 2 +- .../rollback-post_catalog_maindb_92_955.sql | 12 ++++++++++++ .../rollback_catalog_otherdb_92_955.sql | 12 ++++++++++++ .../upgrade-post_catalog_maindb_92_955.sql | 12 ++++++++++++ .../upgrade-post_catalog_otherdb_92_955.sql | 12 ++++++++++++ 13 files changed, 69 insertions(+), 1 deletion(-) create mode 100644 src/include/catalog/upgrade_sql/rollback_catalog_maindb/rollback-post_catalog_maindb_92_955.sql create mode 100644 src/include/catalog/upgrade_sql/rollback_catalog_otherdb/rollback_catalog_otherdb_92_955.sql create mode 100644 src/include/catalog/upgrade_sql/upgrade_catalog_maindb/upgrade-post_catalog_maindb_92_955.sql create mode 100644 src/include/catalog/upgrade_sql/upgrade_catalog_otherdb/upgrade-post_catalog_otherdb_92_955.sql diff --git a/CMakeLists.txt b/CMakeLists.txt index 5aab533a3..a9abe0b5a 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -150,6 +150,12 @@ if(EXISTS ${CMAKE_SOURCE_DIR}/contrib/dolphin) install(FILES ${CMAKE_SOURCE_DIR}/contrib/dolphin/dolphin--4.0.1--4.0.sql DESTINATION share/postgresql/extension/ ) + install(FILES ${CMAKE_SOURCE_DIR}/contrib/dolphin/dolphin--4.0--4.1.sql + DESTINATION share/postgresql/extension/ + ) + install(FILES ${CMAKE_SOURCE_DIR}/contrib/dolphin/dolphin--4.1--4.0.sql + DESTINATION share/postgresql/extension/ + ) install(FILES ${CMAKE_SOURCE_DIR}/contrib/dolphin/openGauss_expr_dolphin.ir DESTINATION share/postgresql/extension/ ) diff --git a/build/script/aarch64_finance_list b/build/script/aarch64_finance_list index 9873ce259..e965232fb 100644 --- a/build/script/aarch64_finance_list +++ b/build/script/aarch64_finance_list @@ -89,6 +89,8 @@ ./share/postgresql/extension/dolphin--2.0.1--2.0.sql ./share/postgresql/extension/dolphin--4.0--4.0.1.sql ./share/postgresql/extension/dolphin--4.0.1--4.0.sql +./share/postgresql/extension/dolphin--4.0--4.1.sql +./share/postgresql/extension/dolphin--4.1--4.0.sql ./share/postgresql/extension/whale.control ./share/postgresql/extension/whale--1.0.sql ./share/postgresql/extension/openGauss_expr_dolphin.ir diff --git a/build/script/aarch64_lite_list b/build/script/aarch64_lite_list index c3545e89b..cb437f39c 100644 --- a/build/script/aarch64_lite_list +++ b/build/script/aarch64_lite_list @@ -47,6 +47,8 @@ ./share/postgresql/extension/dolphin--2.0.1--2.0.sql ./share/postgresql/extension/dolphin--4.0--4.0.1.sql ./share/postgresql/extension/dolphin--4.0.1--4.0.sql +./share/postgresql/extension/dolphin--4.0--4.1.sql +./share/postgresql/extension/dolphin--4.1--4.0.sql ./share/postgresql/extension/openGauss_expr_dolphin.ir ./share/postgresql/extension/file_fdw--1.0.sql ./share/postgresql/extension/plpgsql.control diff --git a/build/script/aarch64_opengauss_list b/build/script/aarch64_opengauss_list index fb5146307..67c148dba 100644 --- a/build/script/aarch64_opengauss_list +++ b/build/script/aarch64_opengauss_list @@ -92,6 +92,8 @@ ./share/postgresql/extension/dolphin--2.0.1--2.0.sql ./share/postgresql/extension/dolphin--4.0--4.0.1.sql ./share/postgresql/extension/dolphin--4.0.1--4.0.sql +./share/postgresql/extension/dolphin--4.0--4.1.sql +./share/postgresql/extension/dolphin--4.1--4.0.sql ./share/postgresql/extension/openGauss_expr_dolphin.ir ./share/postgresql/extension/age--1.0.0.sql ./share/postgresql/extension/age.control diff --git a/build/script/opengauss_release_list_ubuntu_single b/build/script/opengauss_release_list_ubuntu_single index 0f00e69f6..992935a01 100644 --- a/build/script/opengauss_release_list_ubuntu_single +++ b/build/script/opengauss_release_list_ubuntu_single @@ -77,6 +77,8 @@ ./share/postgresql/extension/dolphin--2.0.1--2.0.sql ./share/postgresql/extension/dolphin--4.0--4.0.1.sql ./share/postgresql/extension/dolphin--4.0.1--4.0.sql +./share/postgresql/extension/dolphin--4.0--4.1.sql +./share/postgresql/extension/dolphin--4.1--4.0.sql ./share/postgresql/extension/openGauss_expr_dolphin.ir ./share/postgresql/extension/age--1.0.0.sql ./share/postgresql/extension/age.control diff --git a/build/script/x86_64_finance_list b/build/script/x86_64_finance_list index 36843f405..d230a8f40 100644 --- a/build/script/x86_64_finance_list +++ b/build/script/x86_64_finance_list @@ -89,6 +89,8 @@ ./share/postgresql/extension/dolphin--2.0.1--2.0.sql ./share/postgresql/extension/dolphin--4.0--4.0.1.sql ./share/postgresql/extension/dolphin--4.0.1--4.0.sql +./share/postgresql/extension/dolphin--4.0--4.1.sql +./share/postgresql/extension/dolphin--4.1--4.0.sql ./share/postgresql/extension/whale.control ./share/postgresql/extension/whale--1.0.sql ./share/postgresql/extension/openGauss_expr_dolphin.ir diff --git a/build/script/x86_64_lite_list b/build/script/x86_64_lite_list index 58cedc637..917c10040 100644 --- a/build/script/x86_64_lite_list +++ b/build/script/x86_64_lite_list @@ -47,6 +47,8 @@ ./share/postgresql/extension/dolphin--2.0.1--2.0.sql ./share/postgresql/extension/dolphin--4.0--4.0.1.sql ./share/postgresql/extension/dolphin--4.0.1--4.0.sql +./share/postgresql/extension/dolphin--4.0--4.1.sql +./share/postgresql/extension/dolphin--4.1--4.0.sql ./share/postgresql/extension/openGauss_expr_dolphin.ir ./share/postgresql/extension/file_fdw--1.0.sql ./share/postgresql/extension/plpgsql.control diff --git a/build/script/x86_64_opengauss_list b/build/script/x86_64_opengauss_list index faa707768..88aa80490 100644 --- a/build/script/x86_64_opengauss_list +++ b/build/script/x86_64_opengauss_list @@ -90,6 +90,8 @@ ./share/postgresql/extension/dolphin--2.0.1--2.0.sql ./share/postgresql/extension/dolphin--4.0--4.0.1.sql ./share/postgresql/extension/dolphin--4.0.1--4.0.sql +./share/postgresql/extension/dolphin--4.0--4.1.sql +./share/postgresql/extension/dolphin--4.1--4.0.sql ./share/postgresql/extension/openGauss_expr_dolphin.ir ./share/postgresql/extension/age--1.0.0.sql ./share/postgresql/extension/age.control diff --git a/src/common/backend/utils/init/globals.cpp b/src/common/backend/utils/init/globals.cpp index a0ded481d..dcad0b673 100644 --- a/src/common/backend/utils/init/globals.cpp +++ b/src/common/backend/utils/init/globals.cpp @@ -76,7 +76,7 @@ bool will_shutdown = false; * ********************************************/ -const uint32 GRAND_VERSION_NUM = 92954; +const uint32 GRAND_VERSION_NUM = 92955; /******************************************** * 2.VERSION NUM FOR EACH FEATURE diff --git a/src/include/catalog/upgrade_sql/rollback_catalog_maindb/rollback-post_catalog_maindb_92_955.sql b/src/include/catalog/upgrade_sql/rollback_catalog_maindb/rollback-post_catalog_maindb_92_955.sql new file mode 100644 index 000000000..9f5910a10 --- /dev/null +++ b/src/include/catalog/upgrade_sql/rollback_catalog_maindb/rollback-post_catalog_maindb_92_955.sql @@ -0,0 +1,12 @@ +do $$ +DECLARE +ans boolean; +BEGIN + for ans in select case when count(*)=1 then true else false end as ans from (select extname from pg_extension where extname='dolphin') + LOOP + if ans = true then + ALTER EXTENSION dolphin UPDATE TO '4.0'; + end if; + exit; + END LOOP; +END$$; \ No newline at end of file diff --git a/src/include/catalog/upgrade_sql/rollback_catalog_otherdb/rollback_catalog_otherdb_92_955.sql b/src/include/catalog/upgrade_sql/rollback_catalog_otherdb/rollback_catalog_otherdb_92_955.sql new file mode 100644 index 000000000..9f5910a10 --- /dev/null +++ b/src/include/catalog/upgrade_sql/rollback_catalog_otherdb/rollback_catalog_otherdb_92_955.sql @@ -0,0 +1,12 @@ +do $$ +DECLARE +ans boolean; +BEGIN + for ans in select case when count(*)=1 then true else false end as ans from (select extname from pg_extension where extname='dolphin') + LOOP + if ans = true then + ALTER EXTENSION dolphin UPDATE TO '4.0'; + end if; + exit; + END LOOP; +END$$; \ No newline at end of file diff --git a/src/include/catalog/upgrade_sql/upgrade_catalog_maindb/upgrade-post_catalog_maindb_92_955.sql b/src/include/catalog/upgrade_sql/upgrade_catalog_maindb/upgrade-post_catalog_maindb_92_955.sql new file mode 100644 index 000000000..b33aabd0d --- /dev/null +++ b/src/include/catalog/upgrade_sql/upgrade_catalog_maindb/upgrade-post_catalog_maindb_92_955.sql @@ -0,0 +1,12 @@ +do $$ +DECLARE +ans boolean; +BEGIN + for ans in select case when count(*)=1 then true else false end as ans from (select extname from pg_extension where extname='dolphin') + LOOP + if ans = true then + ALTER EXTENSION dolphin UPDATE TO '4.1'; + end if; + exit; + END LOOP; +END$$; \ No newline at end of file diff --git a/src/include/catalog/upgrade_sql/upgrade_catalog_otherdb/upgrade-post_catalog_otherdb_92_955.sql b/src/include/catalog/upgrade_sql/upgrade_catalog_otherdb/upgrade-post_catalog_otherdb_92_955.sql new file mode 100644 index 000000000..b33aabd0d --- /dev/null +++ b/src/include/catalog/upgrade_sql/upgrade_catalog_otherdb/upgrade-post_catalog_otherdb_92_955.sql @@ -0,0 +1,12 @@ +do $$ +DECLARE +ans boolean; +BEGIN + for ans in select case when count(*)=1 then true else false end as ans from (select extname from pg_extension where extname='dolphin') + LOOP + if ans = true then + ALTER EXTENSION dolphin UPDATE TO '4.1'; + end if; + exit; + END LOOP; +END$$; \ No newline at end of file