postgis.gdal_enabled_drivers — 用于设置 PostGIS 环境中启用的 GDAL 驱动程序的配置选项。 影响 GDAL 配置变量 GDAL_SKIP。
用于设置 PostGIS 环境中启用的 GDAL 驱动程序的配置选项。 影响 GDAL 配置变量 GDAL_SKIP。 该选项可以在 PostgreSQL 的配置文件:postgresql.conf 中设置。 也可以通过连接或事务来设置。
postgis.gdal_enabled_drivers 的初始值也可以通过将环境变量 POSTGIS_GDAL_ENABLED_DRIVERS 和已启用的驱动程序列表传递给启动 PostgreSQL 的进程来设置。
启用GDAL指定的驱动程序可以通过驱动程序的短名称或代码来指定。 驱动程序短名称或代码可以在 GDAL 栅格格式中找到。 可以通过在每个驱动程序之间添加空格来指定多个驱动程序。
|
|
|
当 |
|
|
|
在标准 PostGIS 安装中, |
|
|
|
有关 GDAL_SKIP 的其他信息可在 GDAL 的配置选项中找到。 |
可用性:2.2.0
Set and reset postgis.gdal_enabled_drivers for the current session.
SET postgis.gdal_enabled_drivers = 'ENABLE_ALL';
SET postgis.gdal_enabled_drivers = default;
Set specific drivers for all new connections to a database.
ALTER DATABASE mygisdb SET postgis.gdal_enabled_drivers TO 'GTiff PNG JPEG';
Set the default for the whole database cluster to enable all drivers. This requires superuser access. Also note that database, session, and user settings override this.
This example writes the setting to postgres.auto.conf.
ALTER SYSTEM SET postgis.gdal_enabled_drivers TO 'ENABLE_ALL';
Reload the PostgreSQL configuration so the changed setting is applied.
SELECT pg_reload_conf();