Forums » General Discussion

Thread: Problems with encoding during update

This question is answered. Helpful answers available: 0. Answered answers available: 1.


Permlink Replies: 4 - Pages: 1 - Last Post: Sep 19, 2011 6:31 PM by: Vanya Threads: [ Previous | Next ]
Vanya

Posts: 3
Registered: 9/18/11
Problems with encoding during update
Posted: Sep 18, 2011 4:54 PM
 
  Click to reply to this thread Reply

I have an UTF-8 tables with russian text.
Toad successfully reads data from database and shows it in Data tab.

But when I make update or insert, all russian chars replaces by "?" and text becomes to look like "????? ????? ???, ???..." etc.

"SET NAMES CP1251" does not affect.

Is it bug or feature? How to fix it?

// win7 x64, Toad 5.0.0.345


Scott M. Sanders


Posts: 40
Registered: 1/27/11
Re: Problems with encoding during update
Posted: Sep 19, 2011 5:41 AM   in response to: Vanya
Helpful
  Click to reply to this thread Reply

If it's UTF-8, wouldn't you do "SET NAMES utf8" instead?



Vanya

Posts: 3
Registered: 9/18/11
Re: Problems with encoding during update
Posted: Sep 19, 2011 11:11 AM   in response to: Scott M. Sanders
 
  Click to reply to this thread Reply

Because 1) It does not affect too. 2) I am not sure, but I think Win7 works in cp1251


Mauritz

Posts: 314
Registered: 8/23/07
Re: Problems with encoding during update
Posted: Sep 19, 2011 2:11 PM   in response to: Vanya
Helpful
  Click to reply to this thread Reply

I just tested this in the very soon to be released 6.0 release and a local database and UTF stuff seems to work fine. Are you sure your server is installed to use the UTF8 character set?



Vanya

Posts: 3
Registered: 9/18/11
Re: Problems with encoding during update
Posted: Sep 19, 2011 5:58 PM   in response to: Mauritz
 
  Click to reply to this thread Reply

I have tested on two different remote servers - debian and freebsd. Their both have many normally working bases with utf-8 data.

The problem is that Toad is reading my data correctly, but spoils data when updating(or inserting).

p.s. Ok, i will try to use version 6.0

Message was edited by: Vanya

UPD: Just tested on 6.0 - unfortunately the result is the same. So sad :<

Message was edited by: Vanya

Ooh, I fixed it by adding "character_set_server=utf8" into my.cnf. Thanks.

Message was edited by: Vanya


Legend
Guru: 2001 + pts
Expert: 751 - 2000 pts
Enthusiast: 31 - 750 pts
Novice: 0 - 30 pts
Moderators
Helpful answer (5 pts)
Answered (10 pts)

Point your RSS reader here for a feed of the latest messages in all forums