I'm trying to update a specific text column(WVARCHAR) on sqlite row using sqlite3_bind_text16()
on my C program but unfortunately, only the strings that contains only ascii encoded characters like L"e"
are updated correctly, but the other strings containing unicode characters like L"é"
are updated having the non-ascii characters not stored correctly. here is example how I used the function:
sqlite3_bind_text16(stmt, 1, L"e", -1, SQLITE_STATIC); //e is stored correctly
sqlite3_bind_text16(stmt, 2, L"é", -1, SQLITE_STATIC); //é not stored correctly: modified
I tested that by doing select command using sqlite shell for my program's sqlite database file.
so how to fix that?