(解决--)Caused by: java.sql.SQLException: 无法转换为内部表示 .

org.springframework.jdbc.UncategorizedSQLException: Hibernate operation: could not execute query; uncategorized SQLException for SQL

Caused by: java.sql.SQLException: 无法转换为内部表示

在开发时遇到无法转换为内部表示的问题:犯错原因主要是

Hibernate的映射和pojo的数据类型和数据库的数据类型不匹配

varchar ====java.lang.String

number ====java.lang.double(对有小数点)

number ====java.lang.Integer

时间: 2024-12-31 03:38:10

(解决--)Caused by: java.sql.SQLException: 无法转换为内部表示 .的相关文章

Cause: java.sql.SQLException: 无法转换为内部表示(Mybatis)

公司开发档案系统使用框架:Spring+Struts2+Mybatis+EasyUI,在开发过程中出现sql异常:“Cause: java.sql.SQLException: 无法转换为内部表示”,错误如下: org.springframework.jdbc.UncategorizedSQLException: ### Error querying database. Cause: java.sql.SQLException: 无法转换为内部表示 ### The error may involv

java.sql.SQLException: 无法转换为内部表示 -〉java 查询oracle数据库返回错误信息

java.sql.SQLException: 无法转换为内部表示 Query: SELECT * FROM  nontheasttycoon Parameters: []    at org.apache.commons.dbutils.AbstractQueryRunner.rethrow(AbstractQueryRunner.java:392) ~[commons-dbutils-1.6.jar:1.6]    at org.apache.commons.dbutils.QueryRunn

解决Caused by: java.sql.SQLException: ORA-00933: SQL command not properly ended

是iBATIS.xml这句话出错了 <isNotEmpty prepend="AND" property="beginDt" >a.updatedate >= #beginDt# </isNotEmpty> <isNotEmpty prepend="AND" property="endDt" >a.updatedate >= #endDt# </isNotEmpty>

java.sql.SQLException: 无法转换为内部表示

1. 我出这个错代码:wfef.setRow_num(rs.getInt(rs.getInt(12))); 2. 分析:rs.getInt(12)  得到的是int类型,rs.getInt(rs.getInt(12)) 得到的是String的类型,而wfef.setRow_num()  是int类型 3. 总结:这个错出现的根本原因在于:数据类型不匹配,也就是说数据库中的类型和你的变量类型不匹配

解决sqoop导入报错:Caused by: java.sql.SQLException: Protocol violation

报错信息: 2017-06-15 15:02:15,374 INFO [main] org.apache.hadoop.mapred.MapTask: Ignoring exception during close for [email protected]0 java.io.IOException: java.sql.SQLException: Protocol violation at org.apache.sqoop.mapreduce.db.DBRecordReader.close(DB

Caused by: java.sql.SQLException: Operand should contain 1 column(s)

1.错误描述 [ERROR:]2015-05-05 15:48:55,847 [异常拦截] org.hibernate.exception.DataException: error executing work at org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:135) at org.hibernate.exception.internal.

Caused by: java.sql.SQLException: Parameter index out of range (1 &gt; number of parameters, which is 0

1.错误描述 org.hibernate.exception.GenericJDBCException: error executing work at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:54) at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(Sql

Caused by: java.sql.SQLException: Couldn&#39;t perform the operation commit

1.错误描述 Caused by: java.sql.SQLException: Couldn't perform the operation commit: You can't perform any operations on this connection. It has been automatically closed by Proxool for some reason (see logs). at org.logicalcobwebs.proxool.WrappedConnecti

Caused by: java.sql.SQLException: Field &#39;id&#39; doesn&#39;t have a default value

1.错误描述 org.hibernate.exception.GenericJDBCException: error executing work at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:54) at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(Sql