In D7, if you delete a field from a content type, the field data stays in the database. And yet if you later add that same field back to that same content type, the data does not reappear. Zuh?
It’s the new deleted
field in each field_data_<field_name>
table that governs this behavior. So if you accidentally delete a field and want that data back, just change the deleted
field from 1 to 0.
Kinda cool I guess, though it sort of reminds me of the trash can in WordPress. As far as I can tell, though, there’s no UI for adding back deleted fields.
Where is this field?
Where can I find this “field_data_” field to change?
It's in the database
So if you’d created a field called
headline
, you’d look for a table namedfield_data_field_headline
.This screen shot shows the structure of such a table as it appears in SequelPro.