Python inserts UTF8 string into SQLite
I know there are similar questions, but the answers are different and confusing.
I have this line:
titulo = "Así Habló Zaratustra (Cómic)"
When I try to insert it into a SQLite database, I get the error:
sqlite3.ProgrammingError: You must not use 8-bit bytestrings unless you use a text_factory that can interpret 8-bit bytestrings (like text_factory = str). It is highly recommended that you instead just switch your application to Unicode strings.
I've tried a couple of things with no success. Please, help.
+3
source to share