解决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>


改成

<isNotEmpty property="beginDt">and a.updateDate&gt;=#beginDt#</isNotEmpty><!-- 起初日期 -->

<isNotEmpty property="endDt">and a.updateDate&lt;=#endDt#</isNotEmpty><!-- 结束日期 -->

就好

时间: 2024-10-28 10:55:45

解决Caused by: java.sql.SQLException: ORA-00933: SQL command not properly ended的相关文章

ORA-00933: SQL command not properly ended

今天写了一个小的SQL语句类似下面的这句: UPDATE A SET ID=B.ID FROM A,B WHERE A.NAME=B.NAME 在执行时居然报了"ORA-00933: SQL command not properly ended"这个错误提示信息,SQL语句如此简单,不应该出现错误的!但是事实上确实报错了,仔细看了下没发现那里有问题,百度了一下,出现这个错误的情况还是挺多的,当抛出此错误提示信息,代表着SQL语句本身就是有问题的!(ORA-00933:SQL命令没有正确

(解决--)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 ===

解决Caused by: java.io.IOException: java.io.IOException: error=12, Cannot allocate memory

最近公司一台线上服务器的hbase的regionserver挂掉之后起不起来报错OOM. 这台机器同时装有cassandra,于是停掉cassandra释放内存,重启regionserver失败,同时cassandra再尝试启动也报错Caused by: java.io.IOException: java.io.IOException: error=12, Cannot allocate memory ps -ef发现有很多类似/bin/bash /opt/cloudera-manager/cm

解决Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain value for com.geek.dao.ContentDao.Integer

mybatis报错:Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain value for com.geek.dao.ContentDao.Integer 出错原因:一个手误 <select id="selectAllFirstNavigationName" resultMap="firstNavigation"> SELECT fi

解决Caused by: java.lang.NoSuchMethodException: com.mchange.v2.c3p0.cfg.C3P0Config.&lt;init&gt;()的总结

引起:spring的dao层注入dataSource出现c3p0初始化异常. bug示图: 源码图: 解决: 在填写property属性时,我就纳闷alt+/用不了了,完了之后运行发现初始化出错,然后一看,是因为class引入的类有问题 引入错误的类:com.mchange.v2.c3p0.cfg.C3P0Config 正确的类:com.mchange.v2.c3p0.ComboPooledDataSource

解决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

解决java.sql.SQLException: Incorrect string value: &#39;\xE6\x88\x91\xE7\x9A\x84...&#39; for column &#39;groupName&#39;

今天使用mysql,用java程序往mysql中写数据,出现如下错误: Caused by: java.sql.SQLException: Incorrect string value: '\xD3\xCD\xBB\xAD' for column 'type' at row 1 解法: 创建每张表的时候都必须设置数据编码方式: drop table if exists we_artwork_desc; CREATE TABLE we_artwork_desc ( id VARCHAR(200),