aboutsummaryrefslogtreecommitdiff
path: root/databases/postgresql-plruby/files/createlang.sql
diff options
context:
space:
mode:
Diffstat (limited to 'databases/postgresql-plruby/files/createlang.sql')
-rw-r--r--databases/postgresql-plruby/files/createlang.sql15
1 files changed, 15 insertions, 0 deletions
diff --git a/databases/postgresql-plruby/files/createlang.sql b/databases/postgresql-plruby/files/createlang.sql
new file mode 100644
index 000000000000..0641d1c1e378
--- /dev/null
+++ b/databases/postgresql-plruby/files/createlang.sql
@@ -0,0 +1,15 @@
+--
+-- Execute the following SQL statements to enable PL/Ruby.
+--
+-- $FreeBSD$
+--
+
+CREATE FUNCTION plruby_call_handler() RETURNS OPAQUE
+ AS '!!PLRUBY_SO!!'
+ LANGUAGE 'C';
+
+CREATE TRUSTED PROCEDURAL LANGUAGE 'plruby'
+ HANDLER plruby_call_handler
+ LANCOMPILER 'PL/Ruby';
+
+--