summaryrefslogtreecommitdiff
path: root/src/test/regress/expected
diff options
context:
space:
mode:
authorBruce Momjian <bruce@momjian.us>2003-12-01 21:52:38 +0000
committerBruce Momjian <bruce@momjian.us>2003-12-01 21:52:38 +0000
commit04a4821adef38155b7920ba9eb83c4c3c29156f8 (patch)
treec778c2d286441d98a2453f06f5af9c2b214ffc3e /src/test/regress/expected
parentaf03663878b257f7fb93a80eec03a8dd070b22b7 (diff)
downloadpostgresql-04a4821adef38155b7920ba9eb83c4c3c29156f8.tar.gz
Attached is a patch implementing factorial(), returning numeric. Points
to note: 1) arttype is numeric. I thought this was the best way of allowing arbitarily large factorials, even though factorial(2^63) is a large number. Happy to change to integers if this is overkill. 2) since we're accepting numeric arguments, the patch tests for floats. If a numeric is passed with non-zero decimal portion, an error is raised since (from memory) they are undefined. Gavin Sherry
Diffstat (limited to 'src/test/regress/expected')
-rw-r--r--src/test/regress/expected/create_operator.out14
1 files changed, 6 insertions, 8 deletions
diff --git a/src/test/regress/expected/create_operator.out b/src/test/regress/expected/create_operator.out
index 7685dbe802..df25f35ae7 100644
--- a/src/test/regress/expected/create_operator.out
+++ b/src/test/regress/expected/create_operator.out
@@ -15,19 +15,17 @@ CREATE OPERATOR <% (
negator = >=%
);
CREATE OPERATOR @#@ (
- rightarg = int4, -- left unary
- procedure = int4fac
+ rightarg = int8, -- left unary
+ procedure = numeric_fac
);
CREATE OPERATOR #@# (
- leftarg = int4, -- right unary
- procedure = int4fac
+ leftarg = int8, -- right unary
+ procedure = numeric_fac
);
CREATE OPERATOR #%# (
- leftarg = int4, -- right unary
- procedure = int4fac
+ leftarg = int8, -- right unary
+ procedure = numeric_fac
);
-- Test comments
COMMENT ON OPERATOR ###### (int4, NONE) IS 'bad right unary';
ERROR: operator does not exist: integer ######
-COMMENT ON OPERATOR #%# (int4, NONE) IS 'right unary';
-COMMENT ON OPERATOR #%# (int4, NONE) IS NULL;