This website uses cookies for visitor traffic analysis. By using the website, you agree with storing the cookies on your computer.More information

MySQL und Unicode

Allgemeine Fragen zur Entwicklung von und mit JVx.

MySQL und Unicode

Postby bmgnet » Sat Jan 09, 2010 10:39 am

Ich betreibe eine MySQL DB (5.0.51) mit UTF-8. Am Client kann ich z.B.: Č in einer Tabelle eingeben,
aber nach der Datenaktualisierung (Reload) wird das Zeichen nicht mehr wie gewünscht dargestellt.
Mit der Showcase Applikation funktioniert obiges Problemlos!
bmgnet
 
Posts: 6
Joined: Wed Oct 21, 2009 12:00 pm

Re: MySQL und Unicode

Postby Support@SIB » Sun Jan 10, 2010 12:31 pm

Ein Auszug aus dem MySql 5.x Manual, Kapitel Using Character Sets and Unicode, gibt nähere Auskünfte:

All strings sent from the JDBC driver to the server are converted automatically from native Java Unicode form to the client character encoding, ...


Im Normalfall ist der Zeichensatz abhängig vom Betriebssystem auf dem der JDBC Treiber verwendet wird. Im Falle von JVx ist das der Application Server z.B Tomcat.

Kontrollieren Sie bitte den Zeichensatz des Betriebssystems.

Eine andere Möglichkeit auf das Encoding Einfluß zu nehmen sind Connection Properties:

Code: Select all
jdbc:mysql://<hostname>/<dbname>?useUnicode=yes&characterEncoding=UTF-8

Genauere Informationen finden Sie im MySql Manual.

Anmerkung

Der Application Server für die showcase Anwendung läuft auf einem Server mit UTF-8. Aus diesem Grund gibt es auch keine Probleme mit speziellen Zeichen.
User avatar
Support@SIB
 
Posts: 353
Joined: Mon Sep 28, 2009 1:56 pm


Return to Development (DE)