4 Star 2 Fork 2

sunbingzibo / phpok3w

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
pinpai.php 855 Bytes
一键复制 编辑 原始数据 按行查看 历史
sunbingzibo 提交于 2014-08-08 14:08 . 修改了几个函数
<?php
/**
* Created by PhpStorm.
* User: Administrator
* Date: 14-8-8
* Time: 上午10:12
*/
set_time_limit(0);
$link=MySQL_connect('localhost','root','mmeizhen');
mysql_select_db('zhoucheng');
mysql_query('set names utf8');
for ($i = 0; $i < 1000; $i++)
{
$sqlstr = "select * from xinghao where pinpai is null limit 0,100";
$sql = mysql_query($sqlstr, $link) or die("error");
while ($row = mysql_fetch_array($sql))
{
$consql = "SELECT GROUP_CONCAT(pingpai) as pinpai1 from bearing where new_x='" . $row["xinxinghao"] . "'";
$result = mysql_query($consql, $link);
$resar = mysql_fetch_array($result);
$upsql = "update xinghao set pinpai='" . $resar["pinpai1"] . "' where id=" . $row["id"];
mysql_query($upsql);
echo $row["id"] . "<br />";
}
sleep(1);ob_flush();flush();
}
PHP
1
https://gitee.com/9786/phpok3w.git
git@gitee.com:9786/phpok3w.git
9786
phpok3w
phpok3w
master

搜索帮助