From 3ac9945a33f830fac338dd13751ce039e287479d Mon Sep 17 00:00:00 2001 From: emorino Date: Thu, 12 Aug 2021 14:24:46 +0200 Subject: [PATCH] Ajout install / activation extention postgis --- HowtoPostgreSQL.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/HowtoPostgreSQL.md b/HowtoPostgreSQL.md index 8adcf0d0..12d31562 100644 --- a/HowtoPostgreSQL.md +++ b/HowtoPostgreSQL.md @@ -1370,4 +1370,32 @@ hostname=# select pg_get_functiondef(to_regproc('gen_random_uuid')); AS '$libdir/pgcrypto', $function$pg_random_uuid$function$+ (1 row) +~~~ + +### Activer module `postgis` + +Il faut en premier installé les paquets suivants, exemple sur une instance postgresql 11 : + +~~~ +# apt install postgis postgresql-11-postgis-2.5-scripts +~~~ + +Ensuite il faut faire un `CREATE EXTENTION` dans la base de données ou l'on veux utilisé postgis. + +**ATTENTION** : il ne faut **PAS** créer l'extention dans la base de donnée nommée `postgres` + +~~~ +foo=# CREATE EXTENTION postgis; +~~~ + +Pour activé le support de rasterisation : + +~~~ +foo=# CREATE EXTENTION postgis_raster; +~~~ + +Activé topology : + +~~~ +foo=# CREATE EXTENTION postgis_topology; ~~~ \ No newline at end of file