1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-28 23:42:10 +03:00

Fix DDL command collection for TRANSFORM

Commit b488c580ae, which added the DDL command collection feature,
neglected to update the code that commit cac7658205 had previously
added two weeks earlier for the TRANSFORM feature.

Reported by Michael Paquier.
This commit is contained in:
Alvaro Herrera
2015-06-26 18:17:54 -03:00
parent 4028222468
commit 7d60b2af34
6 changed files with 32 additions and 4 deletions

View File

@ -15,6 +15,7 @@ REGRESS = test_ddl_deparse \
create_domain \
create_sequence_1 \
create_table \
create_transform \
alter_table \
create_view \
create_trigger \

View File

@ -0,0 +1,13 @@
--
-- CREATE_TRANSFORM
--
-- Create a dummy transform
-- The function FROM SQL should have internal as single argument as well
-- as return type. The function TO SQL should have as single argument
-- internal and as return argument the datatype of the transform done.
-- pl/plpgsql does not authorize the use of internal as data type.
CREATE TRANSFORM FOR int LANGUAGE SQL (
FROM SQL WITH FUNCTION varchar_transform(internal),
TO SQL WITH FUNCTION int4recv(internal));
NOTICE: DDL test: type simple, tag CREATE TRANSFORM
DROP TRANSFORM FOR int LANGUAGE SQL;

View File

@ -0,0 +1,14 @@
--
-- CREATE_TRANSFORM
--
-- Create a dummy transform
-- The function FROM SQL should have internal as single argument as well
-- as return type. The function TO SQL should have as single argument
-- internal and as return argument the datatype of the transform done.
-- pl/plpgsql does not authorize the use of internal as data type.
CREATE TRANSFORM FOR int LANGUAGE SQL (
FROM SQL WITH FUNCTION varchar_transform(internal),
TO SQL WITH FUNCTION int4recv(internal));
DROP TRANSFORM FOR int LANGUAGE SQL;