oracle ORA-00910: 为其数据类型指定的长度太长
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/19294028/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
ORA-00910: specified length too long for its datatype
提问by user166013
I have a column in Oracle to store comments of Nvarchar2(2000)
. When a user tries to enter beyond 2000 characters, I get the following error:
我在 Oracle 中有一个列来存储Nvarchar2(2000)
. 当用户尝试输入超过 2000 个字符时,我收到以下错误:
ORA-00910: specified length too long for its datatype.
The NLS_NCHAR_CHARACTERSET
parameter is having AL16UTF16
value.
该NLS_NCHAR_CHARACTERSET
参数具有AL16UTF16
价值。
Is there any way to increase the size to accept up to 6000 characters? My column already has lots of contents, so not sure if I will be able to change the datatype from NVarchar(2000)
to any other.
有没有办法增加大小以接受最多 6000 个字符?我的专栏已经有很多内容,所以不确定我是否能够将数据类型从NVarchar(2000)
任何其他更改。
回答by Przemyslaw Kruglej
Unless you use Oracle 12c, it's not possible to store more than 2000 characters, see the datatypes description here:
除非您使用 Oracle 12c,否则不可能存储超过 2000 个字符,请参阅此处的数据类型说明:
http://docs.oracle.com/cd/B28359_01/server.111/b28320/limits001.htm
http://docs.oracle.com/cd/B28359_01/server.111/b28320/limits001.htm
Instead, you should use the NCLOB datatype.
相反,您应该使用 NCLOB 数据类型。
If you use 12c, check: http://dbasolved.com/2013/06/26/change-varchar2-to-32k-12c-edition/
如果您使用 12c,请检查:http: //dbasolved.com/2013/06/26/change-varchar2-to-32k-12c-edition/