EnterpriseDB / mysql_fdw

PostgreSQL foreign data wrapper for MySQL
Other
531 stars 162 forks source link

a bug when parsing subquery for empty group by #74

Closed dPeS closed 8 years ago

dPeS commented 8 years ago

I got this when PG_TAB is >empty<, a bug probably

select count(*), (select name from FDW_TAB where id = xid) from PG_TAB group by xid;

ERROR: failed to prepare the MySQL query: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '::integer))' at line 1

I'm using newest release

ibrarahmad commented 8 years ago

Please share complete test case

dPeS commented 8 years ago

it looks like it's working on master but not on 2.0.1, I upgraded it recently from different reason and now works ok, ticket to close imo.

dPeS commented 8 years ago

tested on 9cd6963ac76ba62ebb6fd5d584ec4725d0f56424 commit