$str = update t1 set f1=v1 where id=x;update t1 set f1=v2 where id=x2;
mysql_query($str);
为什么这里在php里面无法更新数据库,但copy到mysql又行,
到底怎么样才能在php批量更新mysql数据
mysql_query($str);
为什么这里在php里面无法更新数据库,但copy到mysql又行,
到底怎么样才能在php批量更新mysql数据
mysqli_multi_query可以
mysql_query($str); 引号都没加当然不行啦另外连接数据库是否成功!~你也需要检测下。。