Database 使用带有Python和flask的文本框从数据库获取数据 如何使用文本框从数据库中获取数据,例如某些表行不仅包含 # word that i wrote in textbox but also some characters (% the word wri

Database 使用带有Python和flask的文本框从数据库获取数据 如何使用文本框从数据库中获取数据,例如某些表行不仅包含 # word that i wrote in textbox but also some characters (% the word wri,database,textbox,rows,contains,Database,Textbox,Rows,Contains,使用带有Python和flask的文本框从数据库获取数据 如何使用文本框从数据库中获取数据,例如某些表行不仅包含 # word that i wrote in textbox but also some characters (% the word written in textbox %)? def getdata(): text = request.form['search'] req= "select * from products_urls where pro

使用带有Python和flask的文本框从数据库获取数据 如何使用文本框从数据库中获取数据,例如某些表行不仅包含
# word that i wrote in textbox but also some characters (% the word written in textbox %)?
def getdata():
    text = request.form['search']
    req= "select * from products_urls where product like %text"
    ```