http://blog.csdn.net/caihaijiang/article/details/6438633 --日期格式化
date_format(createtime,'%Y-%m-%d') = '2011-10-17'
得到指定年份、月份、日期
date_format(STR_TO_DATE(birthday,'%Y年%m月%d日'),'%Y') 
 
--模糊查询
错误
1.ibatis中定义
     appname like '%#keyword#%'
2.参数中放入传给ibatis
     param:'%keyword%'
     ibatis:#keyword#
 
正确写法
select * from query_table where appname like concat('%',#keyword#,'%')
 
 
 

iBatis 使用总结的更多相关文章

  1. 值得注意的ibatis动态sql语法格式

    一.Ibatis常用动态sql语法,简单粗暴用一例子 <select id="iBatisSelectList" parameterClass="java.util ...

  2. org.apache.ibatis.binding.BindingException: Invalid bound statement (not found):

    org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): da.huying.usermanag ...

  3. [入门级] visual studio 2010 mvc4开发,用ibatis作为数据库访问媒介(一)

    [入门级] visual studio 2010 mvc4开发,用ibatis作为数据库访问媒介(一) Date  周二 06 一月 2015 By 钟谢伟 Tags mvc4 / asp.net 示 ...

  4. Spring+ibatis动态管理数据源

    Spring动态配置多数据源,即在大型应用中对数据进行切分,并且采用多个数据库实例进行管理,这样可以有效提高系统的水平伸缩性.而这样的方案就会不同于常见的单一数据实例的方案,这就要程序在运行时根据当时 ...

  5. iBatis.net 循环iterate,没有foreach

    3.9.4. Iterate Element This tag will iterate over a collection and repeat the body content for each ...

  6. ibatis 轻松入门

    1.总中的配置文件 <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE sqlMapConfig ...

  7. IBatis.Net使用总结(四)-- IBatis 调用存储过程

    IBatis 调用存储过程 http://www.cnblogs.com/jeffwongishandsome/archive/2010/01/10/1543219.html http://www.c ...

  8. MyBatis-Exception:org.apache.ibatis.exceptions.PersistenceException

    错误信息如下: HTTP Status 500 - org.mybatis.spring.MyBatisSystemException: nested exception is org.apache. ...

  9. Exception:HTTP Status 500 - org.apache.ibatis.binding.BindingException: Invalid bound statement (not found)

    主要错误信息如下: HTTP Status 500 - org.apache.ibatis.binding.BindingException: Invalid bound statement (not ...

  10. ibatis 和 mybatis

    ibatis 在daoImpl 层 继承 SqlMapClientDaoSupport  实现 dao 层的接口. this.getSqlMapClientTemplate().queryForObj ...

随机推荐

  1. PHP开发经常遇到的几个错误

    错误1:foreach循环后留下悬挂指针 在foreach循环中,如果我们需要更改迭代的元素或是为了提高效率,运用引用是一个好办法: $arr = array(1,2,3,4); foreach($a ...

  2. debug 英文翻译

    declaration of 'int a' shadows a parameter :函数参数里,已经有这两个名称的变量了,指定义了同名的参数,造成了隐藏. expected primary-exp ...

  3. (寒假开黑gym)2018 USP Try-outs

    layout: post title: (寒假开黑gym)2018 USP Try-outs author: "luowentaoaa" catalog: true tags: m ...

  4. hdu6162(树链剖分)

    hdu6162 题意 给出一颗带点权的树,每次询问一对节点 \((u, v)\),问 \(u\) 到 \(v\) 的最短路径上所有节点权值在 \([c1, c2]\) 区间内的和. 分析 树链剖分,那 ...

  5. 【kd-tree】bzoj4066 简单题

    同p1176. #include<cstdio> #include<cmath> #include<algorithm> using namespace std; ...

  6. 【字符串哈希】【BKDRhash】【Rabin-Karp算法】模板

    #include<cstdio> #include<iostream> #include<cstring> #include<string> #incl ...

  7. identifier is too long 异常处理

    修改了oracle中的表. 报 identifier is too long 错误 我执行的脚本是: ---备份create table MDT_AGREEMENTMANAGEMENT_2018080 ...

  8. Firefox中好用的几个快捷键

    对于一些经常用FF(firefox)上网的朋友来说, 怎样加快上网的操作速度呢, 使用Firefox快捷键是很好的方法. 本人也经常遇到一些Firefox的很好的快捷键,现在我来告诉大家Firefox ...

  9. Memcached网络模型

    之前用libevent开发了一个流媒体服务器.用线程池实现的.之后又看了memcached的网络相关实现,今天来整理一下memcached的实现流程. memcached不同于Redis的单进程单线程 ...

  10. React脚手架

    所谓脚手架,是指一套基础的开发环境,你只需要简单的配置或者无需配置,就可以直接开发自己的业务代码,而无需劳神在搭建环境上. 比较出名的就是facebook自己出的的脚手架:create-react-a ...