diff --git a/selling/doctype/sales_bom/sales_bom.py b/selling/doctype/sales_bom/sales_bom.py index 420b5a9ffd..a6b123a3c3 100644 --- a/selling/doctype/sales_bom/sales_bom.py +++ b/selling/doctype/sales_bom/sales_bom.py @@ -79,7 +79,7 @@ def get_new_item_code(doctype, txt, searchfield, start, page_len, filters): return webnotes.conn.sql("""select name, description from tabItem where is_stock_item="No" and is_sales_item="Yes" - and name not in (select name from `tabSales BOM`) and %s like "%s" + and name not in (select name from `tabSales BOM`) and %s like %s %s limit %s, %s""" % (searchfield, "%s", get_match_cond(doctype, searchfield),"%s", "%s"), ("%%%s%%" % txt, start, page_len)) \ No newline at end of file