Hello,

I already found a lot of threads about the UTF16 topic, but I couldn't solve
my problem.
I have the following source code:

sqlite3_open_v2("test.sqlite", &Database, SQLITE_OPEN_READWRITE |
SQLITE_OPEN_CREATE, 0);
sqlite3_exec(Database, "PRAGMA encoding = \"UTF-16\"", 0, 0, 0);
sqlite3_prepare16_v2(Database, L"CREATE TABLE user (userID INTEGER NOT NULL
PRIMARY KEY, lastName VARCHAR(50), firstName VARCHAR(50));", -1,
&pStatement, 0);
std::cout << sqlite3_errmsg(Database) << std::endl;

The result is:
near "C": syntax error

I know that the SQL syntax is correct and it is possible to execute that
source under windows.
I don't understand why it doesn't work with Linux.
Does somebody has an idea what's going wrong?

Operating system: 2.6.31-19-generic #56-Ubuntu SMP i686 GNU/Linux
IDE: NetBeans

Regards,
shion
-- 
View this message in context: 
http://old.nabble.com/UTF16---sqlite3_prepare16_v2-tp28643020p28643020.html
Sent from the SQLite mailing list archive at Nabble.com.

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to