On 2014-09-10 21:08, Juri Rudi wrote:
def cerca_def():
cliens = "select cognome, nome, paese from rubrica where
(cognome = '%s' OR nome = '%s' OR paese = '%s')" % (cognome.get(),
nome.get(), paese.get())
Che succede se uno ha un apostrofo nel cognome?
L'errore che stai facendo probabilmente (ma non conosco come si
comporta mysql) e' che i campi vuoti vanno cercati con "nome is null",
non con "nome = ''" e ancora meno con nome = 'None'.
-- Daniele
_______________________________________________
Python mailing list
Python@lists.python.it
http://lists.python.it/mailman/listinfo/python