summaryrefslogtreecommitdiff
path: root/src/test/regress/input/create_function_2.source
diff options
context:
space:
mode:
authorMarc G. Fournier <scrappy@hub.org>1997-04-06 08:29:57 +0000
committerMarc G. Fournier <scrappy@hub.org>1997-04-06 08:29:57 +0000
commite31cb4be3adf6bce2997e03a5d0c2d61ff400730 (patch)
tree09e1b966f8f4943937a6c9e48d598bd9d3b1d6b6 /src/test/regress/input/create_function_2.source
parent588ae64c4402ddf6e9fc8596fa2c53453d577f73 (diff)
downloadpostgresql-e31cb4be3adf6bce2997e03a5d0c2d61ff400730.tar.gz
More splits and cleanups...
Its starting to actually take shape and look as expected...
Diffstat (limited to 'src/test/regress/input/create_function_2.source')
-rw-r--r--src/test/regress/input/create_function_2.source59
1 files changed, 59 insertions, 0 deletions
diff --git a/src/test/regress/input/create_function_2.source b/src/test/regress/input/create_function_2.source
new file mode 100644
index 0000000000..d98f4fd8fa
--- /dev/null
+++ b/src/test/regress/input/create_function_2.source
@@ -0,0 +1,59 @@
+--
+-- FUNCTION DEFINITIONS
+--
+CREATE FUNCTION hobbies(person)
+ RETURNS setof hobbies_r
+ AS 'select * from hobbies_r where person = $1.name'
+ LANGUAGE 'sql';
+
+
+CREATE FUNCTION hobby_construct(text, text)
+ RETURNS hobbies_r
+ AS 'select $1 as name, $2 as hobby'
+ LANGUAGE 'sql';
+
+
+CREATE FUNCTION equipment(hobbies_r)
+ RETURNS setof equipment_r
+ AS 'select * from equipment_r where hobby = $1.name'
+ LANGUAGE 'sql';
+
+
+CREATE FUNCTION user_relns()
+ RETURNS setof name
+ AS 'select relname
+ from pg_class
+ where relname !~ ''pg_.*'' and
+ relkind <> ''i'' '
+ LANGUAGE 'sql';
+
+CREATE FUNCTION pt_in_circle(point, circle)
+ RETURNS int4
+ AS '_OBJWD_/regress_DLSUFFIX_'
+ LANGUAGE 'c';
+
+CREATE FUNCTION overpaid(emp)
+ RETURNS bool
+ AS '_OBJWD_/regress_DLSUFFIX_'
+ LANGUAGE 'c';
+
+CREATE FUNCTION boxarea(box)
+ RETURNS int4
+ AS '_OBJWD_/regress_DLSUFFIX_'
+ LANGUAGE 'c';
+
+CREATE FUNCTION interpt_pp(path, path)
+ RETURNS point
+ AS '_OBJWD_/regress_DLSUFFIX_'
+ LANGUAGE 'c';
+
+CREATE FUNCTION reverse_c16(char16)
+ RETURNS char16
+ AS '_OBJWD_/regress_DLSUFFIX_'
+ LANGUAGE 'c';
+
+--
+-- FUNCTION DYNAMIC LOADING
+--
+LOAD '_OBJWD_/regress_DLSUFFIX_';
+