Mapping an NCLOB to a String property in NHibernate

来源:互联网 发布:林青霞五官数据分析 编辑:程序博客网 时间:2024/06/03 11:44

So I ran into an issue this evening where I needed to map a string property to a NCLOB column but I kept getting:

"ORA-01461: can bind a LONG value only for insert into a LONG column"

Turns out that you should set the column type to "AnsiString" as in:

<property name="Contents" column="CONTENTS" type="AnsiString"/>

 

- Hope this helps someone else out.

0 0
原创粉丝点击