Make cartodbfy return destoid
This commit is contained in:
parent
b7b5be1f3f
commit
565edcb50d
@ -323,10 +323,10 @@ $$ LANGUAGE PLPGSQL;
|
||||
-- Ensure a table is a "cartodb" table (See https://github.com/CartoDB/cartodb/wiki/CartoDB-user-table)
|
||||
|
||||
CREATE OR REPLACE FUNCTION CDB_CartodbfyTable(reloid REGCLASS)
|
||||
RETURNS void
|
||||
RETURNS REGCLASS
|
||||
AS $$
|
||||
BEGIN
|
||||
PERFORM cartodb.CDB_CartodbfyTable('public', reloid);
|
||||
RETURN cartodb.CDB_CartodbfyTable('public', reloid);
|
||||
END;
|
||||
$$ LANGUAGE PLPGSQL;
|
||||
|
||||
@ -343,6 +343,10 @@ $$ LANGUAGE PLPGSQL;
|
||||
-- logic before the table re-write to avoid re-writing if the table
|
||||
-- already has all the necessary columns in place.
|
||||
--
|
||||
-- It returns the destoid of the table. If no rewritting is needed
|
||||
-- the return value will be equal to reloid.
|
||||
--
|
||||
--
|
||||
-- (0) _CDB_check_prerequisites
|
||||
-- As before, this checks the prerequisites before trying to cartodbfy
|
||||
--
|
||||
@ -1121,7 +1125,7 @@ $$ LANGUAGE 'plpgsql';
|
||||
|
||||
|
||||
CREATE OR REPLACE FUNCTION CDB_CartodbfyTable(destschema TEXT, reloid REGCLASS)
|
||||
RETURNS void
|
||||
RETURNS REGCLASS
|
||||
AS $$
|
||||
DECLARE
|
||||
|
||||
@ -1185,5 +1189,6 @@ BEGIN
|
||||
|
||||
END IF;
|
||||
|
||||
RETURN (destschema || '.' || destname)::regclass;
|
||||
END;
|
||||
$$ LANGUAGE 'plpgsql';
|
||||
|
@ -4,7 +4,7 @@ CREATE TRIGGER
|
||||
INSERT 0 1
|
||||
ERROR: Quota exceeded by 3.9990234375KB
|
||||
0
|
||||
|
||||
big
|
||||
INSERT 0 2048
|
||||
INSERT 0 2048
|
||||
INSERT 0 2048
|
||||
|
Loading…
Reference in New Issue
Block a user