代码改变世界

ibatis like查询

2012-06-18 16:57  通心菜  阅读(273)  评论(0编辑  收藏  举报
//Oracle    
SELECT *  FROM Table WHERE  like Column '%'  || #keywords# || '%'  

//mysql
        SELECT *   FROM Table WHERE Column  like CONCAT('%', #keywords#, '%')  

//sqlserver
    SELECT *  
          FROM Table 
          WHERE Column  like '%' + #keywords# +  '%'