From 2d9de85e039ecbe2f9f4b42a3fb80a5e425043b8 Mon Sep 17 00:00:00 2001 From: Emmanuel Garette Date: Sat, 1 Oct 2022 19:08:05 +0200 Subject: [PATCH] add postgresql debug informations --- seed/postgresql/DEBUG.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/seed/postgresql/DEBUG.md b/seed/postgresql/DEBUG.md index c835ba01..d43ed80a 100644 --- a/seed/postgresql/DEBUG.md +++ b/seed/postgresql/DEBUG.md @@ -1 +1,20 @@ pg_dumpall --clean > /srv/database.sql + +Conversion SQL_ASCII vers UTF-8 +=============================== + +Sauvegarde : + +``` +pg_dumpall -c -E UTF8 > sql.sql +``` + +Dans le fichier, remplacer "ENCODING = 'SQL_ASCII'" en "ENCODING = 'UTF8'" et remplacer "LOCALE = 'C'" en "LOCALE = 'fr_FR.UTF-8'". + +ArrĂȘter les applications qui utilise les bases. + +Restaurer : + +``` +psql < sql.sql +```