$sql="SELECT peisonghao FROM ecs_order_info_ly GROUP BY peisonghao HAVING COUNT(*) >1";

$rlt=$GLOBALS['db']->query($sql);

while($data=$GLOBALS['db']->fetch_array($rlt)){

$rand=rand(10000,10000000);

$sql="update ecs_order_info_ly set order_sn='$rand' where order_id=".$data['order_id'];

$GLOBALS['db']->query($sql);

}

SELECT peisonghao FROM ecs_order_info_ly GROUP BY peisonghao HAVING COUNT(*) >1 把重复的行选出来

最新文章

  1. 使用 SoapUI 测试ASP.NET Web API
  2. C#读写文件的方法汇总_C#教程_脚本之家
  3. 字符串截取 方法 String b=a.substring(0, a.indexOf("乘坐"));
  4. RabbitMQ 原文译1.1--HelloWord
  5. block 解析 - 局部变量
  6. 探索Scala(1)-- 运算符重载
  7. js extend的实现
  8. ajax+分页
  9. 安装shellinabox-master
  10. 推荐学习git
  11. Python数据分析Pandas库之熊猫(10分钟一)
  12. 100道Java基础面试题收集整理(附答案)
  13. defaultdict
  14. 【译】如何更好的使用javascript数组
  15. 张高兴的 .NET Core IoT 入门指南:(二)GPIO 的使用
  16. 记录一下gitlab通过CAS登录慢的问题
  17. spring boot配置使用fastjson
  18. noip模拟 五子棋
  19. Salesforce学习第一天
  20. arc073 F many moves(dp + 线段树)

热门文章

  1. 安装Pod时提示ERROR: While executing gem ... (Errno::EPERM) Operation not permitted - /usr/bin/pod
  2. UE3植被工具-支持刷Actor)
  3. POJ 3694 tarjan 桥+lca
  4. speechSynthesis
  5. HDU1004 BALLO0N
  6. Introducing Windows 10 Editions(Windows10版本介绍)
  7. 实时刷新Winform中Label的Text
  8. codeforces 706D (字典树)
  9. ireport开发报表,Java和JSP端如何集成
  10. C++学习笔记16:Linux系统编程基础1