MySQLdb compare lower
tolidtm at gmail.com
Tue Dec 11 22:01:18 CET 2012
Excuse me for the noob question, but is there a way to compare a field
in mysql as lower() somehow?
I have a situation where I compare the SKU in my DB and there are some
SKU that are with lowercase and some with uppercase, how can I solve
this in your opinion ?
def Update_SQL(price, sku):
db = MySQLdb.connect("localhost","getit","opencart",
cursor = db.cursor()
sql = "UPDATE product SET price=%s WHERE sku=%s"
cursor.execute(sql, (price, sku))
More information about the Python-list