Oracle一个诡异的错误——Can bind a LONG value only for insert into a LONG column
CrmProductTaskEndAction : SqlMapClient operation; uncategorized SQLException for SQL []; SQL state [72000]; error code [1461];
--- The error occurred in com/alibaba/intl/bops/crm/syslog/dao/ibatis/sqlmap/CRM_SYSLOG_EMAIL.xml.
--- The error occurred while applying a parameter map.
--- Check the CRM_SYSLOG_EMAIL.insert-InlineParameterMap.
--- Check the statement (update failed).
Error: java.sql.SQLException: ORA-01461: can bind a LONG value only for insert into a LONG column
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:331)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:288)
at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:743)
at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:216)
at oracle.jdbc.driver.T4CPreparedStatement.executeForRows(T4CPreparedStatement.java:955)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1168)
at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3316)
at oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStatement.java:3422)
at com.alibaba.ark.jdbc.PreparedStatementWrapper.execute(PreparedStatementWrapper.java:136)
原因就是字段超长。LONG column是Oracle老的BLOB数据类型,已经deplicated了,Use BLOB instead of LONG。
Datatype
Description
Max Size:Oracle 8
Max Size:Oracle 9i/10g
Max Size:Oracle 11g
Max Size:PL/SQL
PL/SQL Subtypes/Synonyms
VARCHAR2(size) |
Variable length character string having maximum length size bytes. You must specify size |
4000 bytes minimum is 1 |
4000 bytes minimum is 1 |
4000 bytes minimum is 1 |
32767 bytes minimum is 1 |
STRING VARCHAR |
LONG |
Character data of variable length (A bigger version the VARCHAR2 datatype) |
2 Gigabytes |
2 Gigabytes - but now deprecated (provided for backward compatibility only). |
2 Gigabytes - but now deprecated (provided for backward compatibility only). |
32760 bytes Note this is smalller than the maximum width of a LONG column |
|
但是将同样的SQL放在pldev终端直接跑,确实报另外一个错误:
ORA-01401:insert value too large for column
具体参考:Oracle/PLSQL: ORA-01401 Error
为什么同样的SQL,会跑出不同的错误结果,仔细看异常堆栈,发现前面的ORA-01461错误是Oracle JDBC驱动(ojdbc14)抛出来的。
分享到:
相关推荐
Linux上配置DNS服务器所需的bind9包。后缀是.deb的安装包,适用于Ubuntu和debian。安装及配置详情见:http://blog.csdn.net/qq_33069737/article/details/52239394
国内dns环境大家都懂的,自己搞一个也是不错的! PS:该工具为windows 64位版本,里面含有dig工具!
Android 出现“Can’t bind to local 8602 for debugger”错误的解决方法 为了适应Android5.0的开发,把JDK升级到了1.7,然后在ADT中想调试一下程序(我连接的真机),结果报错如下: [2015-04-23 15:31:37 - ddms]...
bind()功能是为每个选择元素的事件绑定处理函数,感兴趣的你可以了解下它的语法bind(type, [data], fn),参数data是作为event.data属性值传递对象的额外数据对象,好好学习希望本可以帮助到你
Pro DNS and BIND guides you through the challenging array of features surrounding DNS, with a special focus on BIND, the worlds most popular DNS implementation. This book unravels the mysteries of DNS...
This utility class can bind a edit menu for ListView, GridView, or other View easily. Welcome star, fork Screenshots How do I use PopupList? Just need a .java file and a little code. PopupList ...
bind bind bind bind
主要介绍了Android 出现“Can't bind to local 8602 for debugger”错误的解决方法的相关资料,需要的朋友可以参考下
dig 是一个 Linux 下用来 DNS 查询信息的工具,全称是Domain Information Groper,与 nslookup 类似,但比 nslookup 功能更强大。Windows 下只有 nslookup,如果也想用到 dig 命令,就只能自己动手安装了。此为适用...
PDOStatement::bindValue — 把一个值绑定到一个参数(PHP 5 >= 5.1.0, PECL pdo >= 0.1.0) 说明 语法 bool PDOStatement::bindValue ( mixed $parameter , mixed $value [, int $data_type = PDO::PARAM_STR ] ) ...
将一个命令的输出内容写入到一个文件里面。如果该文件存在, 就将该文件的内容覆盖; 如果不存在就先创建该文件, 然后再写入内容。 输出重定向,意思就是说,将原来屏幕输出变为文件输出,即将内容输到文件中。 ...
Key features: - Exchange your complete UI without touching any logic. You want to try the new Unity UI instead ...- Easily extendable for other UI, e.g. custom ones. - Easily extendable for custom UI wi
BIND9中文手册 BIND9中文手册 BIND9中文手册 BIND9中文手册 BIND9中文手册
FFmpeg Unity Bind 主要是用来做视频处理,比如视频裁剪、合并、音视频合并等。
The Berkeley Internet Name Domain (BIND) implements a domain name server for a number of operating systems. This document provides basic information about the installation and care of
sqlite3_last_insert_rowid sqlite3_libversion sqlite3_mprintf sqlite3_open sqlite3_open16 sqlite3_prepare sqlite3_prepare16 sqlite3_progress_handler sqlite3_reset sqlite3_result_blob sqlite3_result_...
More complex inline functions may also be put in a .h file for the convenience of the implementer and callers, though if this makes the .h file too unwieldy you can instead put that code in a ...
12. A circuit-switched network can guarantee a certain amount of end-to-end bandwidth for the duration of a call. Most packet-switched networks today (including the Internet) cannot make any end-to-...