import shutil
import time
import pymysql
conn=pymysql.connect(host="222",user="root",password="",db="www",charset="utf8")
cu=conn.cursor()
cu.execute("select xm,wxpic,bh from eyh_yas where hid=769")
rows= cu.fetchall()
s1=time.time()
for row in rows:
d=row[0].replace("/","-")
shutil.copy(row[1], r"./img/"+d.strip()+".jpg")
print(time.time()-s1)