Description
If you change the data type of the ID column to bigint or numeric pg_pathman gives an error and is disabled:
CREATE TABLE items (
id BIGINT PRIMARY KEY,
name TEXT,
code BIGINT);
INSERT INTO items (id, name, code)
SELECT g, md5(g::text), random() * 100000
FROM generate_series(1, 100000) as g;
SELECT create_range_partitions('items', 'id', 1, 1000);
WARNING: Constant type in some check constraint does not match the partitioned column's type
ERROR: Wrong constraint format for RANGE partition "items_1"
HINT: pg_pathman will be disabled to allow you to resolve this issue
CONTEXT: SQL statement "WITH part_data AS (DELETE FROM ONLY items RETURNING *)
INSERT INTO items SELECT * FROM part_data"
PL/pgSQL function partition_data(regclass) line 11 at EXECUTE
SQL statement "SELECT public.partition_data(parent_relid)"
PL/pgSQL function create_range_partitions(regclass,text,anyelement,anyelement,integer,boolean) line 81 at PERFORM
SELECT version()
PostgreSQL 9.5.4 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-17), 64-bit