diff --git a/smart_service/apis/master_api.py b/smart_service/apis/master_api.py index 0f5bc9c..665a1c3 100644 --- a/smart_service/apis/master_api.py +++ b/smart_service/apis/master_api.py @@ -488,7 +488,7 @@ def change_star_data(): updated_list = [] error_list = [] data = frappe.db.sql(''' - select content_type,content,name,parent,replace(content,'**','abcxyz ') as new_content from tabProcedure_Details where content like '%**%'; + select step_name,content_type,content,name,parent,replace(content,'**','abcxyz ') as new_content from tabProcedure_Details where content like '%**%'; ''', as_dict=1) for v in data: try: @@ -505,7 +505,7 @@ def change_star_data(): sts += result[r] FLAG = 0 frappe.db.sql( - f'''update tabProcedure_Details set content = '{sts}' where name = '{v['name']}'; ''') + f'''update tabProcedure_Details set content = "{sts}" where name = '{v['name']}'; ''') v['new_content'] = sts except Exception as e: error_list.append({v['name']: e})