diff --git a/erpnext/accounts/doctype/pricing_rule/pricing_rule.py b/erpnext/accounts/doctype/pricing_rule/pricing_rule.py index da9650e5d07..8728ac91ad0 100644 --- a/erpnext/accounts/doctype/pricing_rule/pricing_rule.py +++ b/erpnext/accounts/doctype/pricing_rule/pricing_rule.py @@ -175,7 +175,7 @@ def get_pricing_rules(args): if parent_groups: if allow_blank: parent_groups.append('') condition = " ifnull("+field+", '') in ('" + \ - "', '".join([d.replace("'", "\\'").replace('"', '\\"') for d in parent_groups])+"')" + "', '".join([d.replace("'", "\\'").replace('"', '\\"').replace("%", "%%") for d in parent_groups])+"')" return condition