Renaming docs does not update global search strings

I copied an instance of ERPNext and applied frappe.rename_docs and changed abbreviation of company and none of the global search strings have been updated.

Is there a function to update my global search strings or any workaround for this?

Ex 1:

Changed names DN-CT-2018-##### to DO-CT-2018. Global Search Strings still show incorrect links to DN.
dos
dns

Ex 2:

Renamed company and abbreviation. None of the related docs are updated in global search strings.
tatc
capitaltraders

I found a workaround: frappe.utils.global_search.rebuild_for_doctype

1 Like

You can go to frappe-bench folder and run

bench rebuild-global-search

It will rebuild the index.

I don’t know what’s up with ERPNext but I got this error running that command:

pymysql.err.ProgrammingError: (1146, u"Table 'atc.tabQuickBooks Migrator' doesn't exist")

I am getting the same error on 2 different instances today (May 16th 2019), but it sill seems the problem I had (same as @saifi0102 's) has been solved.

also I have checked that actually the table tabQuickBooks Migrator does not exist, so the error is logical in that perspective at least.