drizzledump of text columns returning errors during import process

Bug #656018 reported by Patrick Crews
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Drizzle
Fix Released
High
Andrew Hutchings
7.0
Fix Released
High
Andrew Hutchings

Bug Description

The drizzledump-generated output for a text column is causing errors when attempting to import the table / data into Drizzle.

We see this error during the dump/import process:
Error executing query: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near ''ÿØÿà\' at line 1

The dump output is the same whether using drizzledump or mysqldump. The offending INSERT statement begins:
INSERT INTO `dump_table1` VALUES ('ÿØÿà\^@^PJFIF\

My initial thought is this is due to a charset / collation issue as MySQL is using the default charset / collation while Drizzle isn't using the same sets.

I'll provide the MySQL dumpfile for the table so that you can recreate it / try to import it yourself.
My drizzledump command line:
MySQL running on port 19300, Drizzle on port 9306, db used = drizzledump_db

drizzle//client/drizzledump --compact --host=127.0.0.1 --port=19300 --destination-type=database --destination-host=localhost --destination-port=9306 --destination-user=root --destination-database=drizzledump_db --user=root drizzledump_db

Related branches

Revision history for this message
Patrick Crews (patrick-crews) wrote :
Changed in drizzle:
assignee: nobody → Andrew Hutchings (linuxjedi)
status: New → Confirmed
Changed in drizzle:
importance: Undecided → High
milestone: none → 2010-10-25
status: Confirmed → Triaged
Revision history for this message
Andrew Hutchings (linuxjedi) wrote :

Hi Patrick,

I can't import your dump file into MySQL either (5.1.51), it has the same error. I suspect this is an escaping issue with both libmysqlclient and libdrizzle (or it is not valid UTF8 data). But I will need a way to reproduce it (the original insert statement I guess)

Changed in drizzle:
status: Triaged → Incomplete
Revision history for this message
Patrick Crews (patrick-crews) wrote : Re: [Bug 656018] Re: drizzledump of text columns returning errors during import process

Ok, give me a bit and I'll have something up (will likely involve LOAD DATA
INFILE as that was how randgen populated the original table).

On Wed, Oct 13, 2010 at 5:10 AM, Andrew Hutchings <<email address hidden>
> wrote:

> Hi Patrick,
>
> I can't import your dump file into MySQL either (5.1.51), it has the
> same error. I suspect this is an escaping issue with both
> libmysqlclient and libdrizzle (or it is not valid UTF8 data). But I
> will need a way to reproduce it (the original insert statement I guess)
>
> ** Changed in: drizzle
> Status: Triaged => Incomplete
>
> ** Changed in: drizzle/elliott
> Status: Triaged => Incomplete
>
> --
> drizzledump of text columns returning errors during import process
> https://bugs.launchpad.net/bugs/656018
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in A Lightweight SQL Database for Cloud Infrastructure and Web
> Applications: Incomplete
> Status in Drizzle elliott series: Incomplete
>
> Bug description:
> The drizzledump-generated output for a text column is causing errors when
> attempting to import the table / data into Drizzle.
>
> We see this error during the dump/import process:
> Error executing query: You have an error in your SQL syntax; check the
> manual that corresponds to your Drizzle server version for the right syntax
> to use near ''ÿØÿà\' at line 1
>
> The dump output is the same whether using drizzledump or mysqldump. The
> offending INSERT statement begins:
> INSERT INTO `dump_table1` VALUES ('ÿØÿà\^@^PJFIF\
>
> My initial thought is this is due to a charset / collation issue as MySQL
> is using the default charset / collation while Drizzle isn't using the same
> sets.
>
> I'll provide the MySQL dumpfile for the table so that you can recreate it /
> try to import it yourself.
> My drizzledump command line:
> MySQL running on port 19300, Drizzle on port 9306, db used =
> drizzledump_db
>
> drizzle//client/drizzledump --compact --host=127.0.0.1 --port=19300
> --destination-type=database --destination-host=localhost
> --destination-port=9306 --destination-user=root
> --destination-database=drizzledump_db --user=root drizzledump_db
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/drizzle/+bug/656018/+subscribe
>

Revision history for this message
Patrick Crews (patrick-crews) wrote :

CREATE TABLE + blob source file

You can recreate / populate the table with these two files - I tested that it was enough to cause the same error.

Trying to migrate this table from MySQL to Drizzle via drizzledump will repeat this error.

Revision history for this message
Andrew Hutchings (linuxjedi) wrote :

Thanks Patrick, I'll look into it ASAP

Changed in drizzle:
status: Incomplete → Triaged
Revision history for this message
Andrew Hutchings (linuxjedi) wrote :

See bug#661431 for cause, fixed it in drizzledump (which uses a modified clone of that function). Will fix in libdrizzle in bug#661431 at a later date.

Changed in drizzle:
status: Triaged → Fix Committed
Changed in drizzle:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.