2022-08-19 20:30:13 +02:00
|
|
|
pg_dumpall --clean > /srv/database.sql
|
2022-10-01 19:08:05 +02:00
|
|
|
|
|
|
|
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
|
|
|
|
```
|