[postgres-xl-general] something wrong with my Postgres-XL

Alexander Voytsekhovskyy av at mobile-ua.com
Fri Oct 27 22:57:39 PDT 2017


Let’s go with your example first, seems i have a problem even with it

you missed SELECT SQL query, so i tried to suggest it and here is my query plan

ddc_splat=# explain analyze select sum(b) from t1 group by a;
                                                                QUERY PLAN                                                                 
-------------------------------------------------------------------------------------------------------------------------------------------
 Remote Subquery Scan on all (datanode1,datanode2)  (cost=40.60..42.60 rows=200 width=12) (actual time=798.780..841.870 rows=1000 loops=1)
 Planning time: 0.144 ms
 Execution time: 845.622 ms
(3 rows)

any ideas what’s wrong with my Postgres-XL?

> 
> FWIW after doing this on a 2-node cluster:
> 
>    create table t (a int, b int, c int);
>    create table t1 () inherits (t) to node (datanode_1);
>    create table t2 () inherits (t) to node (datanode_2);
> 
>    insert into t1 select mod(i,1000), i, i
>                     from generate_series(1,10000000) s(i);
> 
>    insert into t2 select mod(i,1000), i, i
>                     from generate_series(1,10000000) s(i);
> 
>    vacuum analyze t;
> 
> I do get a plan like this:
> 
>                         QUERY PLAN
> -------------------------------------------------------------
> Finalize GroupAggregate
>   Group Key: a
>   ->  Remote Subquery Scan on all (dn1,dn2)
>         ->  Sort
>               Sort Key: t.a
>               ->  Gather
>                     Workers Planned: 4
>                     ->  Partial HashAggregate
>                           Group Key: t.a
>                           ->  Append
>                                 ->  Parallel Seq Scan on t
>                                 ->  Parallel Seq Scan on t1
>                                 ->  Parallel Seq Scan on t2
> (13 rows)
> 
> Which seems mostly reasonable, I believe.
> 
> regards
> 
> -- 
> Tomas Vondra                  http://www.2ndQuadrant.com
> PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services




More information about the postgres-xl-general mailing list