Added cast for numeric[]

This commit is contained in:
Andrew Kane
2021-06-11 03:32:47 -07:00
parent 77d54333f6
commit 154e4334fb
6 changed files with 28 additions and 0 deletions

View File

@@ -97,6 +97,9 @@ CREATE FUNCTION array_to_vector(real[], integer, boolean) RETURNS vector
CREATE FUNCTION array_to_vector(double precision[], integer, boolean) RETURNS vector
AS 'MODULE_PATHNAME' LANGUAGE C IMMUTABLE STRICT PARALLEL SAFE;
CREATE FUNCTION array_to_vector(numeric[], integer, boolean) RETURNS vector
AS 'MODULE_PATHNAME' LANGUAGE C IMMUTABLE STRICT PARALLEL SAFE;
-- casts
CREATE CAST (vector AS vector)
@@ -111,6 +114,9 @@ CREATE CAST (real[] AS vector)
CREATE CAST (double precision[] AS vector)
WITH FUNCTION array_to_vector(double precision[], integer, boolean) AS IMPLICIT;
CREATE CAST (numeric[] AS vector)
WITH FUNCTION array_to_vector(numeric[], integer, boolean) AS IMPLICIT;
-- operators
CREATE OPERATOR <-> (