1. 程式人生 > >Hibernate : Disabling contextual LOB creation as createClob() method threw error處理

Hibernate : Disabling contextual LOB creation as createClob() method threw error處理

在applicationContext.xml檔案中加入下面一行即可:

<prop key="hibernate.temp.use_jdbc_metadata_defaults">false</prop> 

如下所示:

<property name="hibernateProperties">

<props>
<!-- 指定Hibernate的連線方言 -->
<prop key="hibernate.dialect">
org.hibernate.dialect.MySQL5InnoDBDialect</prop>
<!--是否根據Hiberante對映建立資料表 -->
<prop key="hibernate.hbm2ddl.auto">update</prop>
<prop key="hibernate.show_sql">true</prop>
<prop key="hibernate.format_sql">true</prop>
<prop key="hibernate.temp.use_jdbc_metadata_defaults">false</prop>
</props>

</property>