instr

MySQL: select * from tableName where name like '%helloworld%';
Oracle:select * from tableName where instr(name,'helloworld')>0;
select BLACK_VALUE, COUNT(*)as total
         from EC_COUPONS_BLACK
         where IS_DELETE='N'

 AND   BLACK_TYPE='goods'
           and IS_ALL_COUPONS='Y'
       and   instr(','||BLACK_VALUE||',',','||(select goods_id from goods where goods_no = '133163'and is_delete = 'N')||',') >0
 GROUP BY BLACK_VALUE

 

posted @ 2019-01-11 15:00  小啊菜鸡  阅读(467)  评论(0编辑  收藏  举报