Re: [HACKERS] Postgres_fdw join pushdown - INNER - FULL OUTER join combination generating wrong result

2016-04-20 Thread Robert Haas
On Tue, Mar 29, 2016 at 10:20 AM, Ashutosh Bapat wrote: >> I think the reason for that is in foreign_join_ok. This in that function: >> >> wrongly pulls up remote_conds from joining relations in the FULL JOIN >> case. I think we should not pull up such conditions in the FULL JOIN case. >> > > Ri

Re: [HACKERS] Postgres_fdw join pushdown - INNER - FULL OUTER join combination generating wrong result

2016-04-15 Thread Etsuro Fujita
On 2016/04/14 15:20, Ashutosh Bapat wrote: On Thu, Apr 14, 2016 at 8:42 AM, Etsuro Fujita mailto:fujita.ets...@lab.ntt.co.jp>> wrote: As you mentioned, we could support FULL JOIN fully, by encapsulating a joining relation with conditions into a subquery. And ISTM that it is relati

Re: [HACKERS] Postgres_fdw join pushdown - INNER - FULL OUTER join combination generating wrong result

2016-04-13 Thread Ashutosh Bapat
On Thu, Apr 14, 2016 at 8:42 AM, Etsuro Fujita wrote: > On 2016/03/29 23:20, Ashutosh Bapat wrote: > >> I think the reason for that is in foreign_join_ok. This in that >> function: >> >> wrongly pulls up remote_conds from joining relations in the FULL >> JOIN case. I think we sh

Re: [HACKERS] Postgres_fdw join pushdown - INNER - FULL OUTER join combination generating wrong result

2016-04-13 Thread Etsuro Fujita
On 2016/03/29 23:20, Ashutosh Bapat wrote: I think the reason for that is in foreign_join_ok. This in that function: wrongly pulls up remote_conds from joining relations in the FULL JOIN case. I think we should not pull up such conditions in the FULL JOIN case. Right. Fo

Re: [HACKERS] Postgres_fdw join pushdown - INNER - FULL OUTER join combination generating wrong result

2016-03-30 Thread Rajkumar Raghuwanshi
Thanks Ashutosh for the patch. I have applied and tested it. Now getting proper result for reported issue. Thanks & Regards, Rajkumar Raghuwanshi QMG, EnterpriseDB Corporation On Tue, Mar 29, 2016 at 7:50 PM, Ashutosh Bapat < ashutosh.ba...@enterprisedb.com> wrote: > > Observation:_ Inner join a

Re: [HACKERS] Postgres_fdw join pushdown - INNER - FULL OUTER join combination generating wrong result

2016-03-29 Thread Ashutosh Bapat
> Observation:_ Inner join and full outer join combination on a table >> >> generating wrong result. >> >> SELECT * FROM lt; >> c1 >> >>1 >>2 >> (2 rows) >> >> SELECT * FROM ft; >> c1 >> >>1 >>2 >> (2 rows) >> >> \d+ ft >> Foreign table "p

Re: [HACKERS] Postgres_fdw join pushdown - INNER - FULL OUTER join combination generating wrong result

2016-03-28 Thread Etsuro Fujita
On 2016/03/28 18:17, Rajkumar Raghuwanshi wrote: I am testing postgres_fdw join pushdown feature for PostgreSQL 9.6 DB, and I observed below issue._ Observation:_ Inner join and full outer join combination on a table generating wrong result. SELECT * FROM lt; c1 1 2 (2 rows) SELEC

[HACKERS] Postgres_fdw join pushdown - INNER - FULL OUTER join combination generating wrong result

2016-03-28 Thread Rajkumar Raghuwanshi
Hi, I am testing postgres_fdw join pushdown feature for PostgreSQL 9.6 DB, and I observed below issue. *Observation:* Inner join and full outer join combination on a table generating wrong result. SELECT * FROM lt; c1 1 2 (2 rows) SELECT * FROM ft; c1 1 2 (2 rows) \d+ ft