From ba3094b4486c5d2fe62ab15a694a292c8c3e1cf9 Mon Sep 17 00:00:00 2001 From: Charles Bochet Date: Sun, 15 Oct 2023 16:45:17 +0200 Subject: [PATCH] Fix script windows init.sql --- infra/dev/postgres/init.sql | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/infra/dev/postgres/init.sql b/infra/dev/postgres/init.sql index d77757352f..5123e987ca 100644 --- a/infra/dev/postgres/init.sql +++ b/infra/dev/postgres/init.sql @@ -1,10 +1,10 @@ SELECT 'CREATE DATABASE "default"' -WHERE NOT EXISTS (SELECT FROM pg_database WHERE datname = 'default'); +WHERE NOT EXISTS (SELECT FROM pg_database WHERE datname = 'default')\gexec SELECT 'CREATE DATABASE "test"' -WHERE NOT EXISTS (SELECT FROM pg_database WHERE datname = 'test'); +WHERE NOT EXISTS (SELECT FROM pg_database WHERE datname = 'test')\gexec SELECT 'CREATE USER twenty PASSWORD ''twenty''' -WHERE NOT EXISTS (SELECT FROM pg_user WHERE usename = 'twenty'); +WHERE NOT EXISTS (SELECT FROM pg_user WHERE usename = 'twenty')\gexec -SELECT 'ALTER ROLE twenty superuser'; +SELECT 'ALTER ROLE twenty superuser'\gexec