From 9bc38f70bb70f647ce36f0c0e53dbe8e18d905ac Mon Sep 17 00:00:00 2001 From: Nicolas Boisselier Date: Fri, 5 Jan 2018 14:21:20 +0000 Subject: [PATCH] lib/postgres/continent.sql --- lib/postgres/continent.sql | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 lib/postgres/continent.sql diff --git a/lib/postgres/continent.sql b/lib/postgres/continent.sql new file mode 100644 index 00000000..a296fabd --- /dev/null +++ b/lib/postgres/continent.sql @@ -0,0 +1,18 @@ +DROP TABLE IF EXISTS continent; +CREATE TABLE IF NOT EXISTS continent ( + id char(3) PRIMARY KEY, + name varchar(200) +); +GRANT ALL ON TABLE continent TO www; +GRANT ALL ON TABLE continent TO nico; +GRANT ALL ON TABLE continent TO root; +BEGIN TRANSACTION; +DELETE FROM continent; +INSERT INTO continent VALUES ('AF','Africa'); +INSERT INTO continent VALUES ('AS','Asia'); +INSERT INTO continent VALUES ('EU','Europe'); +INSERT INTO continent VALUES ('NA','North America'); +INSERT INTO continent VALUES ('OC','Oceania'); +INSERT INTO continent VALUES ('SA','South America'); +INSERT INTO continent VALUES ('AN','Antarctica'); +COMMIT; -- 2.47.3