summaryrefslogtreecommitdiff
path: root/tests/phpunit/data/db/postgres/functions.sql
diff options
context:
space:
mode:
Diffstat (limited to 'tests/phpunit/data/db/postgres/functions.sql')
-rw-r--r--tests/phpunit/data/db/postgres/functions.sql12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/phpunit/data/db/postgres/functions.sql b/tests/phpunit/data/db/postgres/functions.sql
new file mode 100644
index 00000000..3086d4d5
--- /dev/null
+++ b/tests/phpunit/data/db/postgres/functions.sql
@@ -0,0 +1,12 @@
+-- Postgres test file for DatabaseTest::testStoredFunctions()
+
+CREATE FUNCTION mw_test_function()
+RETURNS INTEGER
+LANGUAGE plpgsql AS
+$mw$
+DECLARE foo INTEGER;
+BEGIN
+ foo := 21;
+ RETURN foo * 2;
+END
+$mw$;