pymysql.err.ProgrammingError: (1146, "Table '_34114c3aa28f74aa.tabFRnD' doesn't exist")

I deleted the FRnD doctype a year ago. Everything was working fine, but suddenly when I tried to rename an employee, the following error appeared:

pymysql.err.ProgrammingError: (1146, "Table '_34114c3aa28f74aa.tabFRnD' doesn't exist")

Please help me resolve this.

Use command

bench migrate

Can you add the table again

I tried this command, but it’s not working — it still shows the same error.

@RK_1214 You might using this doctype somewhere in the code

No, I checked everything. I am not using that doctype anywhere. I also checked in MariaDB, but that doctype is not found .

use the below command in the db to check are there any orphaned DocField records

SELECT * FROM `tabDocField` WHERE `parent` = ‘FRnD’;

Show : Unknown column ‘‘FRnD’’ in ‘WHERE’

contact me we will resolve that issue. @RK_1214