# Strange SQL Error when trying to create new custom field

**URL:** <https://forum.mautic.org/t/strange-sql-error-when-trying-to-create-new-custom-field/22135>\
**Category:** Product Support\
**Created:** [December 23, 2021, 9:39am UTC](https://forum.mautic.org/t/strange-sql-error-when-trying-to-create-new-custom-field/22135 "2021-12-23T09:39:15Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![pjrobertson](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/pjrobertson/32/2073_2.png) [@pjrobertson](https://forum.mautic.org/u/pjrobertson)\
**Post date:** [May 20, 2022, 9:15am UTC](https://forum.mautic.org/t/strange-sql-error-when-trying-to-create-new-custom-field/22135/3 "2022-05-20T09:15:28Z")

</div>

For other googlers, I found a solution here: [Cannot Create New Custom Fields. SQLSTATE[42S22] Error - #11 by mikew](https://forum.mautic.org/t/cannot-create-new-custom-fields-sqlstate-42s22-error/23961/11)

1. Run `alter table leads drop column generated_email_domain`
2. Re-run migrations: `php bin/console doctrine:migration:migrate`

---

_[View the full topic](https://forum.mautic.org/t/strange-sql-error-when-trying-to-create-new-custom-field/22135)._
