oracle long raw的休眠映射 [英] hibernate mapping for oracle long raw

查看:95
本文介绍了oracle long raw的休眠映射的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试为oracle数据库创建一个休眠映射.该日期基从oracle 8之前就已经很老了,但是现在已经在10上了.不推荐使用此数据类型,应将其转换为Blob.

I try to create a hibernate mapping for an oracle database. The datebase is pretty old from before oracle 8 but is now on 10. Hibernate reverse engineering balks at a long raw column. This datatype is deprecated and should be converted to blob.

但这不是我的数据库.如果客户拒绝转换,休眠映射将是什么样?

But this is not my database. If the customer refuses to convert how would a hibernate mapping look like ?

推荐答案

尝试将其映射到byte[].

如果得到java.sql.SQLException: Stream has already been closed,则尝试在OJDBC驱动程序的连接属性中设置useFetchSizeWithLongColumn = true.请参见 OracleDriver API

If you get java.sql.SQLException: Stream has already been closed, then try setting useFetchSizeWithLongColumn = true in the connection properties for the OJDBC driver. See the OracleDriver API

这篇关于oracle long raw的休眠映射的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆