We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8d28db3 commit 2099e5dCopy full SHA for 2099e5d
server/routes.py
@@ -13,13 +13,13 @@ def index():
13
14
if name:
15
cursor.execute(
16
- "SELECT * FROM books WHERE name LIKE :name", {'name': f"%{name}%"}
+ "SELECT * FROM books WHERE name LIKE '%" + name + "%'"
17
)
18
books = [Book(*row) for row in cursor]
19
20
elif author:
21
22
- "SELECT * FROM books WHERE author LIKE :author", {'author': f"%{author}%"}
+ "SELECT * FROM books WHERE author LIKE '%" + author + "%'"
23
24
25
0 commit comments