我不小心删除了一个自定义用户字段。这是否意味着它已从数据库中完全删除,还是仍然存在?
如果它仍然存在,是否有办法恢复它(除了还原备份)?或者能否通过数据浏览器访问其内容?
我不小心删除了一个自定义用户字段。这是否意味着它已从数据库中完全删除,还是仍然存在?
如果它仍然存在,是否有办法恢复它(除了还原备份)?或者能否通过数据浏览器访问其内容?
I’m 95% sure a deleted custom field is gone forever.
If you can’t see it in data explorer, it’s not there anymore.
Just a thought, but surely there would be a way to recreate the Custom Field and hack together a script to retrieve and refill the data from within a backup using a temporary cloud server to write out the data from the original Custom Field?
Thanks for your thoughts. Yes, that’s obviously what backups are for. I don’t know what the smartest procedure would be for restoring user field content for, say, thousands of users. For me, the number the easiest procedure was to just do it manually. And that was actually surprisingly easy, so I mention it here (from memory, so I may have missed some detail):
.sql file.目前,删除自定义字段(如果其 field_type 为 dropdown,则涉及表 user_fields 和 user_fields_options)并不会删除用户的实际值(表 user_custom_fields)。因此,一个快速(但可能具有风险:请先备份)的变通方法是:
user_fields 中的 id 替换为旧的 id(这需要数据库的管理员权限):UPDATE user_fields SET id=1 WHERE id=3;(假设 3 是新 id,1 是旧 id)。user_field_options 表中执行类似操作。