highgo=# drop database template1;
ERROR: 42809: cannot drop a template database
highgo=# UPDATE pg_database SET datistemplate='false' WHERE datname='template1';
UPDATE 1
highgo=# drop database template1;
DROP DATABASE
highgo=# create database template1 template template0;
CREATE DATABASE
highgo=# UPDATE pg_database SET datistemplate='true' WHERE datname='template1';
UPDATE 1
PG重建临时库
最新推荐文章于 2024-08-17 09:13:05 发布