import pymysql
connect = pymysql.connect(user = 'm',
            password = 'M',
            db = 'x',
            host = 'rm',
            port = 3306,
            charset = 'utf8'
            )
con = connect.cursor()
bu=0
buu=0
def du(ab):
    sql="select count(*) from {} where bzz='0'".format(ab)
    try:
        count1=con.execute(sql)
        connect.commit()
    except:
        connect.commit()
    count2=con.fetchall()
    if count2[0][0]<10:
        sql1="update bm51 set bzz='0'"
        con.execute(sql1)
        connect.commit()
        
        

 

相关文章:

  • 2021-08-04
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-01-05
  • 2021-06-19
  • 2021-07-13
  • 2021-05-17
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-08-25
  • 2022-01-29
  • 2021-08-09
相关资源
相似解决方案