WEB开发网
开发学院WEB开发Jsp APPFUSE中使用CLOB类型 阅读

APPFUSE中使用CLOB类型

 2008-01-05 18:43:21 来源:WEB开发网   
核心提示:更改applicationContext-hibernate.xml文件为<beans> <!-- Hibernate sessionFactory --> <bean id="sessionFactory" class="org.sPRingframew

更改applicationContext-hibernate.xml文件为

<beans>
   <!-- Hibernate sessionFactory -->
   <bean id="sessionFactory" class="org.sPRingframework.orm.hibernate.LocalSessionFactoryBean">
     <property name="dataSource"><ref bean="dataSource"/></property>
     <property name="mappingResources">
       <list>
         <value>model/Role.hbm.xml</value>
          ......
        <value>model/policy/Policycontent.hbm.xml</value>
       </list>
     </property>
    
     <property name="lobHandler"><ref bean="OracleLobHandler"/></property>
    
     <property name="hibernateProperties">
      <props> 
         <prop key="hibernate.dialect">net.sf.hibernate.dialect.Oracle9Dialect</prop>
        <prop key="hibernate.show_sql">true</prop>
        <prop key="hibernate.jdbc.batch_size">15</prop>
      </props>
     </property>
   </bean>

   <bean id="oracleLobHandler" class="org.springframework.jdbc.support.lob.OracleLobHandler" lazy-init="true">
     <property name="nativeJdbcExtractor"><ref local="nativeJdbcExtractor"/></property>
   </bean>

   <bean id="nativeJdbcExtractor" class="org.springframework.jdbc.support.nativejdbc.SimpleNativeJdbcExtractor">
   </bean>

   <!-- Transaction manager for a single Hibernate SessionFactory (alternative to JTA) -->
   <bean id="transactionManager" class="org.springframework.orm.hibernate.HibernateTransactionManager">

Tags:APPFUSE 使用 CLOB

编辑录入:爽爽 [复制链接] [打 印]
赞助商链接