Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

as you can see I pip all the requirements to run the app successfully but give me the same error what the solution for this

image text in transcribed

image text in transcribed

as you can see I pip all the requirements to run the app successfully but give me the same error what the solution for this one

and I try from MYSQLdb import MYSQL ... mysql = MYSQL (app)

still same problem !!!! ..... thanks in advance

File Edit Format View Help pip install Flask-MySQL db pip install mysql-connector pip install flask-bcrypt pip install PyMySQL pip install mysql-connector-python import pymysql import mysql.connector as sql_db import MySQLdb.cursors import MySQL dbfrom MySQL db import MYSQL import re import mysql.connector as mysql host = mydb = sql_db.connect "remotemysql.com", user = "CgMqc7wq4" password = "AOnouv1030" database = 'eCgMqC7wq4" cursor=mydb. cursor() cursor = mysql.connection.cursor (MySQL db. cursors.DictCursor) cursor.execute('SELECT * FROM users WHERE user name = %S AND password - %s', (username, pas account - cursor.fetchone() 1tst/ rv = selt.dispatch_request() File "/usr/local/lib/python3.9/site-packages/flask/app.py", line 1936, in dispat return self.view_functions[rule.endpoint](**req.view_args) File "/home/ubuntu/workspace/1tst/application.py", line 111, in login3 cursor - mysql.connection.cursor(MySQLdb.cursors.DictCursor) AttributeError: module 'mysql.connector.connection has no attribute cursor. INFO: 192.168.39.1 - - [01/Jan/2021 22:29:59] "POST /login3 HTTP/1.0- 500 - Google Sticky Na

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Intelligent Information And Database Systems Asian Conference Aciids 2012 Kaohsiung Taiwan March 2012 Proceedings Part 2 Lnai 7197

Authors: Jeng-Shyang Pan ,Shyi-Ming Chen ,Ngoc-Thanh Nguyen

2012th Edition

3642284892, 978-3642284892

More Books

Students also viewed these Databases questions