> Any idea? Please, anyone can help me?

How did you put your data into database? I guess you did that with
command line utility. And as your console wasn't set to have UTF-8
charset then contents of pais now is not in UTF-8. But jdbc driver
tries to treat it as UTF-8 and so you don't see what you want to see.
To check this guess execute this query:

select nom_pais, hex(nom_pais) from pais;

You can execute it in command line utility and see if hex contents has
correct UTF-8 encoding as it should be.


Pavel


On Sun, Jul 3, 2011 at 2:40 PM, Fabiana Nascimento <fabia...@gmail.com> wrote:
> Hello,
>
> I'm having problem with accented characters when getting text data from
> sqlite3 with Java (sqlite jdbc).  When i query in command line, the result
> came correct with accentuation. For example:
>
> *sqlite> select nom_pais from pais ;
> Itália
> Rússia
> *
> But, when I query from java app, it's work wrong, as:
>
> *nome do país: It li
> nome do país: R£ssi
> *
> I tried set properties on connection:
>
> *Properties prop = new Properties();
> prop.put("charSet", "UTF-8");
> this.conn = DriverManager.getConnection("jdbc:sqlite:" + file, prop);
> *
> And set system properties before get result:
> *
> System.setProperty("file.encoding", "UTF-8");*
>
> But nothing doesn't work...
> Any idea? Please, anyone can help me?
>
> best regards
>
> Fabiana
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to