我试着基于这个创建函数CREATE OR REPLACE FUNCTION week_num_year(_date date) return ceil((to_char(_date,'DDD')::integer+(to_char(('01-01-'||_year)::date,'D')::integer%7-我的配置: PostgreSQL 9.2
我已经通过Homebrew安装了Postgresql@9.6和Postgis。然而,通过Homebrew安装Postgis会将Postgresql的最新版本安装在10作为依赖项,而将Postgresql固定在9.6.5会阻止通过Homebrew安装Postgis。执行'CREATE EXTENSION postgis;‘返回:
ERROR: could not open extension control file "/usr/