Re: mysql_fdw trouble

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: Dane Foster <studdugie(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: mysql_fdw trouble
Date: 2015-10-29 18:28:01
Message-ID: 56326531.7070706@aklaver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 10/29/2015 11:20 AM, Dane Foster wrote:
> On Thu, Oct 29, 2015 at 2:04 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us
> <mailto:tgl(at)sss(dot)pgh(dot)pa(dot)us>> wrote:
>
> Dane Foster <studdugie(at)gmail(dot)com <mailto:studdugie(at)gmail(dot)com>> writes:
> > Installation and set up worked flawlessly but when I run the following query
> > ...
> > ​I get the following error:​
> > ​ERROR: failed to prepare the MySQL query:
> > FUNCTION latest.btrim does not exist
>
> It looks like mysql_fdw is messing up by sending the trim() checks for
> remote execution when there is no suitable function on the remote side.
> Don't know whether that's a bug in mysql_fdw, or whether there's some
> setup you're supposed to perform on the mysql server and have omitted.
>
> regards, tom lane
>
> ​I think you are correct about mysql_fdw "... sending the trim() checks
> for remote execution" because according to the docs:
>
> "The latest version will push-down the foreign table where clause to the
> foreign server. The where condition on the foreign table will be
> executed on the foreign server hence there will be fewer rows to to
> bring across to PostgreSQL. This is a performance feature."
>
> I guess using mysql_fdw is a no-go for my data migration needs.

Before you give up I would file an issue here:

https://github.com/EnterpriseDB/mysql_fdw/issues

including the MySQL version also.

This issue:

https://github.com/EnterpriseDB/mysql_fdw/issues/42

indicates this type of thing has come up before and was fixed.

>
>
> Dane
> ​
>

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Eric Schwarzenbach 2015-10-29 18:29:34 Re: Domain check constraint not honored?
Previous Message Dane Foster 2015-10-29 18:20:46 Re: mysql_fdw trouble