Valid SQL?

John Salerno johnjsal at
Tue May 23 17:40:19 CEST 2006

Harlin Seritt wrote:
> I am using the exact same query string generated and it works when i
> type it in the MySQL client but doesn't work when using the MySQLdb
> module. 

I've been messing around with mysqldb lately, and one reason I get your 
error message is if I'm not closing parentheses properly.

Can you paste the exact Python code that you are using here, as well as 
the MySQL code used in the client window? I assume in the client you use 
a semicolon, but in Python you don't?

I don't know if you'd get that particular error if the problem is 
something like the values not matching to their type, especially since 
you say it works on the client but not in Python.

More information about the Python-list mailing list