Problem with Guids in MySQL Loader

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for MySQL
Post Reply
dgilmour77
Posts: 3
Joined: Thu 28 Feb 2019 23:31

Problem with Guids in MySQL Loader

Post by dgilmour77 » Thu 03 Oct 2019 02:23

I have a MariaDB 10.3.14 table with a BINARY column into which a GUID is stored. I found that when I bulk loaded data into the table using MySqlLoader that I would get generated SQL syntax errors on some records but not others.

To look into this, I enabled logging in MariaDB and noticed that the INSERT statements were including the binary data directly into the INSERT statement, which of course caused syntax errors.

When I added a custom mapper and excluded the binary column, the tables loaded without error.

Shouldn't MySqlLoader encode binary literals -- perhaps as HEX?

Thanks

Shalex
Site Admin
Posts: 8829
Joined: Thu 14 Aug 2008 12:44

Re: Problem with Guids in MySQL Loader

Post by Shalex » Sat 05 Oct 2019 17:51

Please add "Binary As Guid=true;" to your connection string.

Does this help?

Post Reply