Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can add duplicate field to content type #9

Open
swanback opened this issue Dec 3, 2013 · 0 comments
Open

Can add duplicate field to content type #9

swanback opened this issue Dec 3, 2013 · 0 comments

Comments

@swanback
Copy link

swanback commented Dec 3, 2013

Backup your database first. Add field called "Field 1" to a content type. Add that same field again. It adds the duplicate field to the customm_fields table, and then throws a db error at the last moment:
pic1
pic4
pic5

Now delete the duplicate field, and here's where it starts to go bad:
pic2
because indeed, the field has been deleted from the content type table, even though you only deleted one of the two same-named fields.
pic3
And now there is no apparent way to recover without manually intervening in the db. You can't delete the original field and re-add it to sync things back up because it fails on dropping the field from the table:

Can't DROP 'field_1'; check that column/key exists

ALTER TABLE test DROP field_1

So you have to add a field called field_1 to the affected content type record structure by hand, then you can delete and re-add to make sure everything is good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant