Reputation: 13
I created a database from the Edict files with java and i used for that SQLite.
SQLite by default encode the string in UTF-8
Here is a sample of the database: sample
If i do
Select* FROM entry
In Java i get the japanese words in their "correct" form (graphical representation at least).
But if i try and do.
Select * FROM entry WHERE wordJP LIKE '食べる'"
I obviously get nothing. That makes it very hard to find the definition of a word.
Can someone explain why this is occuring, and how to solve it ? I kind of understand that it is a problem of encoding but i don't understand where it happens and why.
Upvotes: 0
Views: 1092
Reputation: 13
So i managed to solve this:
Upvotes: 1
Reputation: 24651
From your link,
[EDICT] is a plain text document in EUC-JP coding.
If you query strings are encoded in UTF-8, matching will fail.
You should probably try to convert the database into UTF-8 when you fill-in your sqlite database.
Upvotes: 0