カスタムユーザーフィールドを誤って削除してしまいました。これはデータベースから完全に削除されたということでしょうか、それともまだ残っているのでしょうか?
もし残っている場合、バックアップを復元する以外に、取り消す方法やデータエクスプローラーを通じて内容にアクセスする方法はありますか?
カスタムユーザーフィールドを誤って削除してしまいました。これはデータベースから完全に削除されたということでしょうか、それともまだ残っているのでしょうか?
もし残っている場合、バックアップを復元する以外に、取り消す方法やデータエクスプローラーを通じて内容にアクセスする方法はありますか?
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 についても同様の処理を行う必要がある