Форум сайта python.su
Есть такой кусок кода:
c.execute("SELECT code FROM %s WHERE name = %s AND producer = %s ORDER BY prefix ASC LIMIT 1",
(self.mysql["table"], product[0][0], product[0][1]))
Офлайн
sql = "SELECT code FROM " + self.mysql["table"] + " WHERE name = %s AND producer = %s ORDER BY prefix ASC LIMIT 1"
c.execute(sql, (product[0][0], product[0][1]))
Отредактировано (Ноя. 22, 2009 00:27:42)
Офлайн