mirror of
https://github.com/postgres/postgres.git
synced 2025-07-15 19:21:59 +03:00
Change PROCEDURE to FUNCTION in CREATE OPERATOR syntax
Since procedures are now a different thing from functions, change the CREATE OPERATOR syntax to use FUNCTION in the clause that specifies the function. PROCEDURE is still accepted for compatibility. Reported-by: Peter Geoghegan <pg@bowt.ie> Reviewed-by: Jonathan S. Katz <jonathan.katz@excoventures.com>
This commit is contained in:
@ -4,7 +4,7 @@
|
||||
CREATE OPERATOR ## (
|
||||
leftarg = path,
|
||||
rightarg = path,
|
||||
procedure = path_inter,
|
||||
function = path_inter,
|
||||
commutator = ##
|
||||
);
|
||||
CREATE OPERATOR <% (
|
||||
@ -107,7 +107,7 @@ ERROR: at least one of leftarg or rightarg must be specified
|
||||
CREATE OPERATOR #@%# (
|
||||
leftarg = int8
|
||||
);
|
||||
ERROR: operator procedure must be specified
|
||||
ERROR: operator function must be specified
|
||||
-- Should fail. CREATE OPERATOR requires USAGE on TYPE
|
||||
BEGIN TRANSACTION;
|
||||
CREATE ROLE regress_rol_op3;
|
||||
@ -202,4 +202,4 @@ WARNING: operator attribute "Restrict" not recognized
|
||||
WARNING: operator attribute "Join" not recognized
|
||||
WARNING: operator attribute "Hashes" not recognized
|
||||
WARNING: operator attribute "Merges" not recognized
|
||||
ERROR: operator procedure must be specified
|
||||
ERROR: operator function must be specified
|
||||
|
@ -5,7 +5,7 @@
|
||||
CREATE OPERATOR ## (
|
||||
leftarg = path,
|
||||
rightarg = path,
|
||||
procedure = path_inter,
|
||||
function = path_inter,
|
||||
commutator = ##
|
||||
);
|
||||
|
||||
|
Reference in New Issue
Block a user