zoukankan      html  css  js  c++  java
  • 数据库去空格 去table 去回车符号 去重

    1 update bd_prod_cate c set c.cate_name = replace(c.cate_name,chr(9),'')//去掉tab符号的
    2 update bd_prod_cate c set c.cate_name = replace(c.cate_name,chr(10),'')//去掉回车符号的
    3 update bd_prod_cate c set c.cate_name = trim(c.cate_name)//去掉空格符号的

    delete from tabname t1
     where rowid <> (select min(rowid)
                       from tabname  t2
                      where t1.col_name = t2.col_name
                        and t1.id != t2.id);

    delete from userinfo where sss in
    (select sss from
    (select sss from userinfo group by sss having count(sss)>1) tmp1)
    and id not in
    (select id from
    (select min(id) id from userinfo group by sss having count(sss)>1) tmp2);
  • 相关阅读:
    7A
    map最最最基本用法
    cccc超级酱油心得
    scu-4445
    初学算法之广搜
    初学算法之最基础的stl队列
    初学算法之筛选素数法
    go 虎牙爬取
    php使用xpath爬取内容
    go xpath
  • 原文地址:https://www.cnblogs.com/Struts-pring/p/11045309.html
Copyright © 2011-2022 走看看