SQL-Error importing HTML mails from mm2 archive (mbox) or those havin binary attachments
I try to import mails from an mm2 mbox archive file. This generally works out but some emails are missing. Errors indicate problems with SQL special chars (maybe '--' or similar when separating attachments). The following error is an example:
ProgrammingError: (1064, u'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 \'_binary\'<html>\\n<head>\\n<meta http-equiv=\\"Content-Type\\" content=\\"text/html; c\' at line 1')
I am using the following ubuntu/debian packages:
* mailman3 3.1.1-9
* mailman3-full 3.1.1-9
* mailman3-web 0+20170523-14
* python-django-mailman3 1.1.0-4
* python-mailmanclient 3.1.1-5
* python3-mailman-hyperkitty 1.1.0-4
* mysql-server 5.7.25-0ubuntu0.18.04.2
* mysql-server-5.7 5.7.25-0ubuntu0.18.04.2
* mysql-server-core-5.7 5.7.25-0ubuntu0.18.04.2
I changed the charset & collation of the mailman-web (incl. hyperkitty's) tables from latin1 to UTF8_mb4, which was neccessary to fix errors importing UTF8 mail.
Kind regards
-m4tze