Fix sql query in set_expired_status
diff --git a/erpnext/selling/doctype/quotation/quotation.py b/erpnext/selling/doctype/quotation/quotation.py
index ba34dff..ac2c242 100644
--- a/erpnext/selling/doctype/quotation/quotation.py
+++ b/erpnext/selling/doctype/quotation/quotation.py
@@ -187,7 +187,7 @@
def set_expired_status():
frappe.db.sql("""UPDATE `tabQuotation` SET status = 'Expired'
- WHERE status != 'Expired' AND 'valid_till < %s""" , (nowdate()))
+ WHERE status != 'Expired' AND 'valid_till' < %s""", (nowdate()) )
@frappe.whitelist()
def make_sales_invoice(source_name, target_doc=None):