From 8a25d3d31a1c65206b352736b40f2ca9713ce0b0 Mon Sep 17 00:00:00 2001 From: Graham Date: Wed, 24 Feb 2021 21:58:25 +0000 Subject: [PATCH] Use CREATE EXTENSION IF NOT EXISTS in V1__init.sql The user running the migration might not have superuser permissions. Using IF NOT EXISTS allows a root user to install the extension manually, and then the migration will succeed as an unprivileged user. Signed-off-by: Graham --- .../main/resources/org/openrs2/archive/migrations/V1__init.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/archive/src/main/resources/org/openrs2/archive/migrations/V1__init.sql b/archive/src/main/resources/org/openrs2/archive/migrations/V1__init.sql index 3a24461a..4ca263d0 100644 --- a/archive/src/main/resources/org/openrs2/archive/migrations/V1__init.sql +++ b/archive/src/main/resources/org/openrs2/archive/migrations/V1__init.sql @@ -1,5 +1,5 @@ -- @formatter:off -CREATE EXTENSION uint; +CREATE EXTENSION IF NOT EXISTS uint; CREATE TABLE games ( id SERIAL PRIMARY KEY NOT NULL,