如何在 Windows 7 上为 Postgresql 9.2 创建表空间?

Ste*_*han 3 postgresql windows tablespaces postgresql-9.2

我尝试运行这个简单的命令:

CREATE TABLESPACE tb_rec
  OWNER postgres
  LOCATION 'd:/tablespaces';
Run Code Online (Sandbox Code Playgroud)

但是,未创建表空间,我收到以下消息:

ERREUR:  n'a pas pu configurer les droits du répertoire « d:/tablespaces » : Permission denied
Run Code Online (Sandbox Code Playgroud)

对于非法语人士:

ERROR: was not able to configure the directory rights « d:/tablespaces » : Permission denied
Run Code Online (Sandbox Code Playgroud)

我没有找到任何 postgres 用户 ( net user) 并且我被困在这个......

如何将目录访问权限授予 postgres?

Windows 7
Postgres 9.2

Cra*_*ger 6

对于 PostgreSQL 9.2 及更高版本,没有postgres系统用户(默认情况下)。它作为NETWORK SERVICE.

创建d:\tablespaces并赋予NETWORK SERVICESERVICE RÉSEAU法语)“完全控制权”。这应该够了吧。