# Help! Mautic unusable - Contact data scrambled

**URL:** <https://forum.mautic.org/t/help-mautic-unusable-contact-data-scrambled/25158>\
**Category:** Product Support\
**Tags:** mautic-4\
**Created:** [August 24, 2022, 2:30pm UTC](https://forum.mautic.org/t/help-mautic-unusable-contact-data-scrambled/25158 "2022-08-24T14:30:27Z")\
**Posts on this page:** 1\
**Showing post:** 15

<div class="post-metadata">

**Author:** ![entrepositive](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/entrepositive/32/9645_2.png) [@entrepositive](https://forum.mautic.org/u/entrepositive)\
**Post date:** [September 7, 2022, 1:42pm UTC](https://forum.mautic.org/t/help-mautic-unusable-contact-data-scrambled/25158/15 "2022-09-07T13:42:01Z")

</div>

@mzagmajster I tried a lot of different angles here and followed your suggestions above as well.

I was able to upload the csv into a new\_leads table, then truncate data from leads table and copy data over from new\_leads table, leaving structure the way it was. On the front end this cleaned up the data A LOT, however it’s not fixed yet. Contact IDs are (mostly) consistently in the incorrect column, despite their being in the correct column in the DB…

I guess I made one or more mistakes in the data migration and or tampering with the generated\_email\_domain column.

In the effort to solve this issue rapidly, I have created an opportunity:

> [@1-time MySQL leads table update/repair from CSV](https://forum.mautic.org/t/1-time-mysql-leads-table-update-repair-from-csv/25280):
>
> The opportunity is: I made a bad API call and it totally wrecked my leads table, with corrupted data that got split up over multiple columns - very messy. I recovered the data, fortunately, in a CSV file with ~3k contacts incl anon. I also have a backup of the live DB in its current state (with corrupted leads data), so we can run through this process as many times as we need. I managed to get the leads table rebuilt from the CSV, but it’s not clean and not 100% correct. Front end in Mautic st…

I need help on this. I’ve spoken with a Mautic developer who can’t manage the MySQL side, and a MySQL expert who doesn’t know Mautic… I’m stuck here.

EP

---

_[View the full topic](https://forum.mautic.org/t/help-mautic-unusable-contact-data-scrambled/25158)._
