Bonjour,

Je souhaite passer ma BDD en UTF-16le pour premettre la saisie de caractères chinois.
J'ai convertit tous mes fichiers Java dans Eclipse en UTF-16le et j'ai changé l' Interclassement pour la connexion au serveur en UTF-16le_general_ci.
Voici mon fichier hibernate.cfg.xml :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
 
<?xml version="1.0"?>
<!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Configuration DTD 3.0//EN"
                                         "http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
 <session-factory >
  <!-- Database connection settings -->
  <property name="connection.driver_class">com.mysql.jdbc.Driver</property>
  <property name="connection.url">jdbc:mysql://localhost/liveview</property>
  <property name="connection.username">admin</property>
  <property name="connection.password">test</property>
  <property name="connection.useUnicode">true</property>
  <property name="connection.characterEncoding">UTF-16</property>
  <property name="connection.charSet">UTF-16</property>
  <!-- JDBC connection pool (use the built-in) -->
  <property name="connection.pool_size">1</property>
  <!-- SQL dialect -->
  <property name="dialect">org.hibernate.dialect.MySQLDialect</property>
  <!-- Enable Hibernate's automatic session context management -->
  <property name="current_session_context_class">thread</property>
  <!-- Disable the second-level cache -->
  <property name="cache.provider_class">org.hibernate.cache.NoCacheProvider</property>
  <!-- Echo all executed SQL to stdout -->
  <property name="show_sql">false</property>
  <!-- Drop and re-create the database schema on startup -->
  <property name="hbm2ddl.auto">update</property>
  <property name="hibernate.format_sql">true</property>
  <property name="hibernate.use_sql_comments">true</property>
  <property name="hibernate.dialect">org.hibernate.dialect.MySQLDialect</property>
  <!-- Mapping files -->
  <mapping resource="boite.hbm.xml"/>
  <mapping resource="PreReglage.hbm.xml"/>
  <mapping resource="Analyse.hbm.xml"/>
  <mapping resource="User.hbm.xml"/>
  <mapping resource="Temperature.hbm.xml"/>
  <mapping resource="TemperatureConsigne.hbm.xml"/>
 </session-factory>
</hibernate-configuration>
Cependant j'ai l'erreur suivante à la connexion :
nov. 05, 2015 9:09:48 AM org.hibernate.annotations.common.reflection.java.JavaReflectionManager <clinit>
INFO: HCANN000001: Hibernate Commons Annotations {4.0.5.Final}
nov. 05, 2015 9:09:48 AM org.hibernate.Version logVersion
INFO: HHH000412: Hibernate Core {4.3.10.Final}
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Environment <clinit>
INFO: HHH000206: hibernate.properties not found
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Environment buildBytecodeProvider
INFO: HHH000021: Bytecode provider name : javassist
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Configuration configure
INFO: HHH000043: Configuring from resource: hibernate.cfg.xml
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Configuration getConfigurationInputStream
INFO: HHH000040: Configuration resource: hibernate.cfg.xml
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: boite.hbm.xml
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: PreReglage.hbm.xml
nov. 05, 2015 9:09:48 AM org.hibernate.internal.util.xml.DTDEntityResolver resolveEntity
WARN: HHH000223: Recognized obsolete hibernate namespace http://hibernate.sourceforge.net/. Use namespace http://www.hibernate.org/dtd/ instead. Refer to Hibernate 3.6 Migration Guide!
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: Analyse.hbm.xml
nov. 05, 2015 9:09:48 AM org.hibernate.internal.util.xml.DTDEntityResolver resolveEntity
WARN: HHH000223: Recognized obsolete hibernate namespace http://hibernate.sourceforge.net/. Use namespace http://www.hibernate.org/dtd/ instead. Refer to Hibernate 3.6 Migration Guide!
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: User.hbm.xml
nov. 05, 2015 9:09:48 AM org.hibernate.internal.util.xml.DTDEntityResolver resolveEntity
WARN: HHH000223: Recognized obsolete hibernate namespace http://hibernate.sourceforge.net/. Use namespace http://www.hibernate.org/dtd/ instead. Refer to Hibernate 3.6 Migration Guide!
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: Temperature.hbm.xml
nov. 05, 2015 9:09:48 AM org.hibernate.internal.util.xml.DTDEntityResolver resolveEntity
WARN: HHH000223: Recognized obsolete hibernate namespace http://hibernate.sourceforge.net/. Use namespace http://www.hibernate.org/dtd/ instead. Refer to Hibernate 3.6 Migration Guide!
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: TemperatureConsigne.hbm.xml
nov. 05, 2015 9:09:48 AM org.hibernate.internal.util.xml.DTDEntityResolver resolveEntity
WARN: HHH000223: Recognized obsolete hibernate namespace http://hibernate.sourceforge.net/. Use namespace http://www.hibernate.org/dtd/ instead. Refer to Hibernate 3.6 Migration Guide!
nov. 05, 2015 9:09:48 AM org.hibernate.cfg.Configuration doConfigure
INFO: HHH000041: Configured SessionFactory: null
nov. 05, 2015 9:09:48 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl configure
WARN: HHH000402: Using Hibernate built-in connection pool (not for production use!)
nov. 05, 2015 9:09:48 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl buildCreator
INFO: HHH000401: using driver [com.mysql.jdbc.Driver] at URL [jdbc:mysql://localhost/liveview]
nov. 05, 2015 9:09:48 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl buildCreator
INFO: HHH000046: Connection properties: {useUnicode=true, user=admin, password=****, characterEncoding=UTF-16, charSet=UTF-16}
nov. 05, 2015 9:09:48 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl buildCreator
INFO: HHH000006: Autocommit mode: false
nov. 05, 2015 9:09:48 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl configure
INFO: HHH000115: Hibernate connection pool size: 1 (min=1)
Initial SessionFactory creation failed.org.hibernate.exception.SQLGrammarException: Error calling Driver#connect
nov. 05, 2015 9:09:48 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl stop

INFO: HHH000030: Cleaning up connection pool [jdbc:mysql://localhost/liveview]
Exception in Application start method
Je tiens à préciser qu'en tout le projet était en UTF-8, je n'avais aucun soucis de connexion.

Je vous remercie par avance pour votre aide.