Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
PostgreSQL česká template1 šablona
/* PostgreSQL česká template1 */
UPDATE pg_database SET datistemplate = false WHERE datname = 'template1';
DROP DATABASE template1;
CREATE DATABASE template1 template=template0 encoding='UTF-8' LC_COLLATE='cs_CZ.UTF-8' LC_CTYPE='cs_CZ.UTF-8';
COMMENT ON DATABASE template1 IS 'Výchozí česká databáze';
UPDATE pg_database SET
datacl = (SELECT datacl FROM pg_database WHERE datname = 'template0'),
datistemplate = true
WHERE datname = 'template1';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.