Ad Widget

Collapse

partman.create_parent overlap issue on trends and trends_uint

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • metal
    Member
    • Nov 2019
    • 42

    #1

    partman.create_parent overlap issue on trends and trends_uint

    I am following this tutorial to achieve postgresql partitioning. I am using postgresql v13.

    Anyway, I am facing issues with trends and trends_uint tables partitioningas of below.

    Code:
    SELECT partman.create_parent('public.trends', 'clock', 'native', 'monthly', null, 12, 'on', null, true, 'seconds');
    
    ERROR: partition "trends_p2022_05" would overlap partition "trends_p2022_04"
    CONTEXT: SQL statement "ALTER TABLE public.trends ATTACH PARTITION public.trends_p2022_05 FOR VALUES FROM ('1651352400') TO ('1654030800')"
    PL/pgSQL function create_partition_time(text,timestamp with time zone[],boolean,text) line 249 at EXECUTE
    PL/pgSQL function partman.create_parent(text,text,text,text,text[],integer,text,text,boolean,text,text,text[],boolean,text,boolean) line 473 at assignment
    DETAIL:
    HINT:
    CONTEXT: PL/pgSQL function create_partition_time(text,timestamp with time zone[],boolean,text) line 479 at RAISE
    PL/pgSQL function partman.create_parent(text,text,text,text,text[],integer,text,text,boolean,text,text,text[],boolean,text,boolean) line 473 at assignment
    DETAIL:
    HINT:
    CONTEXT: PL/pgSQL function partman.create_parent(text,text,text,text,text[],integer,text,text,boolean,text,text,text[],boolean,text,boolean) line 771 at RAISE

    HTML Code:
    SELECT partman.create_parent('public.trends', 'clock', 'native', 'monthly', null, 12, 'on', null, true, 'seconds');
    
    ERROR: partition "trends_uint_p2022_05" would overlap partition "trends_uint_p2022_04"
    CONTEXT: SQL statement "ALTER TABLE public.trends_uint ATTACH PARTITION public.trends_uint_p2022_05 FOR VALUES FROM ('1651352400') TO ('1654030800')"
    PL/pgSQL function create_partition_time(text,timestamp with time zone[],boolean,text) line 249 at EXECUTE
    PL/pgSQL function partman.create_parent(text,text,text,text,text[],integer,text,text,boolean,text,text,text[],boolean,text,boolean) line 473 at assignment
    DETAIL:
    HINT:
    CONTEXT: PL/pgSQL function create_partition_time(text,timestamp with time zone[],boolean,text) line 479 at RAISE
    PL/pgSQL function partman.create_parent(text,text,text,text,text[],integer,text,text,boolean,text,text,text[],boolean,text,boolean) line 473 at assignment
    DETAIL:
    HINT:
    CONTEXT: PL/pgSQL function partman.create_parent(text,text,text,text,text[],integer,text,text,boolean,text,text,text[],boolean,text,boolean) line 771 at RAISE
    Any idea how to solve these couple of issues.

    Thanks!
    Last edited by metal; 22-06-2021, 18:37.
Working...