I always forget, can't remember. Googling kills lots of time. This blog is only for myself, but if you get any help from this, it will be a bonus for me.
Thursday, October 08, 2009
MySQL unicode query in python
It’s very easy to run MySQL Unicode query in python. Just use the Unicode string by putting u on the front of string and use \u for Unicode char.
q = u"select * from tableName where column01 = \"\u09e7\u09e8\"" cursor.execute(q)
No comments:
Post a Comment