(tablename,data)
return bool(count)
写入数据库
写入数据库
写入数据库
def InsertIntoDB(tablename,data):
    """写入数据库
    """
    sql = forEachPlusInsertProps(tablename,data)
    conn = dbpool.connection(write=True,tablename=tablename)
    cursor = conn.cursor()
    count = cursor.execute(sql)
    conn.commit()
    cursor.close()
    conn.close()
    return bool(count)
def InsertIntoDB ( tablename , data ) : sql = forEachPlusInsertProps ( tablename , data ) conn = dbpool . connection ( write = True , tablename = tablename ) cursor = conn . cursor ( ) count = cursor . execute ( sql ) conn . commit ( ) cursor . close ( ) conn . close ( ) return bool ( count )