From 2a391ae80d75ac3ef6374b989b71d15a3e4fa0e9 Mon Sep 17 00:00:00 2001 From: Victor Lacasse-Beaudoin Date: Thu, 29 Jun 2023 17:18:38 -0400 Subject: [PATCH] =?UTF-8?q?Cr=C3=A9er=20les=20tables=20seulement=20si=20el?= =?UTF-8?q?les=20n'existent=20pas=20d=C3=A9j=C3=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- models/models.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/models/models.go b/models/models.go index c3f4af8..1589aee 100644 --- a/models/models.go +++ b/models/models.go @@ -1,12 +1,12 @@ package models const Schema = ` -CREATE TABLE programmes ( +CREATE TABLE IF NOT EXISTS programmes ( id TEXT PRIMARY KEY, titre TEXT ); -CREATE TABLE membres ( +CREATE TABLE IF NOT EXISTS membres ( id VARCHAR(7) PRIMARY KEY, last_name TEXT, first_name TEXT, -- 2.45.2