Data Missing / Loss

Hi,
I modified some DocTypes and added a few custom fields based on my requirements. However, after upgrading the version, the custom fields I added are missing, along with their data. What is the solution to recover my data, and what is the correct method to add custom fields in the future?

Hi @ayankar

Hope you made a backup before migrating :crossed_fingers:

Thats why frappe made the upgrade-safe Custom Field Doctype - Customizing DocTypes

Before the upgrade, I customized the DocType using the ‘Customize’ option from the module page. This time, I made the same changes directly in the DocType, and after adding my custom fields (the same ones I had added earlier), all the data was automatically restored.