justingit / dada-mail

Self-Hosted, Full Featured, Email Mailing List Manager. Announcement + Discussion Lists, Web-based Installer, Installs with minimal dependencies, sendmail/SMTP/Amazon SES supported
https://dadamailproject.com
GNU General Public License v2.0
172 stars 40 forks source link

Duplicate entry error on updating Geo data on clickthrough #1177

Open dickmo opened 9 months ago

dickmo commented 9 months ago

This has been happening for a log time. I replaces in your code "Insert into" with "Replace into" to eliminate errors. Using MYsql DB in file profile/fields.pm line 190.

DBD::mysql::st execute failed: Duplicate entry 'xxla@optonline.net' for key 'email' at DADA/Profile/Fields.pm line 201. problems updating fields with geo ip data: cannot do statement (at insert)! Duplicate entry 'xxla@optonline.net' for key 'email' at DADA/Logging/Clickthrough.pm line 1682. at DADA/Logging/Clickthrough.pm line 1967. DBD::mysql::st execute failed: Duplicate entry 'xxxxmann@optonline.net' for key 'email' at DADA/Profile/Fields.pm line 201. DBD::mysql::st execute failed: Duplicate entry 'xxxxmann@optonline.net' for key 'email' at DADA/Profile/Fields.pm line 201.

justingit commented 9 months ago

I'll have to look at this bug (and fix) a little more closely - REPLACE INTO isn't supported for PostgreSQL, so I may be looking for a different solution.