How to move one doctype attachements files to another doctype attachements

I have one doctype take it as Student in that doctype i have lot of attachements. I want to move in one doctype for example I have another doctype name was School

How to move the attachements?


Attachements are really another doctype. Search for “File” in awesome bar.
You will see all your files attached … Each file is attached to a specific doctype and to a name (to a particular student in your case …) …

Executing a SQL UPDATE query from console you would change the doctype wich your files are attached to …

update `tabFile`set attached_to_name='your_school_name', attached_to_doctype='School' where attached_to_name='your_student_name' and attached_to_doctype='Student'

Please, note that table names could be different … be careful and previous backup!
Hope this helps.

1 Like

This solution is create but i thought is there any inbuild funtion is there are not.

Thanks for the response