From afe377a9b10b5c1b2badc74d4b9b636e7c4d0cbf Mon Sep 17 00:00:00 2001 From: Pacien TRAN-GIRARD Date: Tue, 27 Jan 2015 18:01:45 +0100 Subject: Add E-R model and SQL bootstrap scripts --- res/sql/functions/pg_gen_uuid.sql | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 res/sql/functions/pg_gen_uuid.sql (limited to 'res/sql/functions/pg_gen_uuid.sql') diff --git a/res/sql/functions/pg_gen_uuid.sql b/res/sql/functions/pg_gen_uuid.sql new file mode 100644 index 0000000..c592385 --- /dev/null +++ b/res/sql/functions/pg_gen_uuid.sql @@ -0,0 +1,9 @@ +CREATE OR REPLACE FUNCTION gen_uuid() + RETURNS VARCHAR +AS ' +BEGIN + + RETURN upper(cast(uuid_generate_v4() AS VARCHAR)); + +END; +' LANGUAGE plpgsql; -- cgit v1.2.3