Hello.
In my application, I have the need to store strings with non-latin characters in a SQLite database.
But when I insert them, they become corrupt.

When i bind the string to the prepared statement, i do make sure it is in UTF-8: sqlite3_bind_text(sentence_insert_statement, 1, [string UTF8String], -1, SQLITE_TRANSIENT); //Where "string" is the string i am trying to insert. I thought that might be the problem of SQLite itself, but when I make an sql file in the UTF-8 encoding, like 'insert into sentences (sentence) values ("привет");' and perform .read (the name of my sql file), it works absolutely fine. Am I missing something important when inserting strings to my db programmatically?

I really hope you can help.
Thank you in advance,
Timofey._______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to