'Setting up queries for MySQL DB on PyMySQL
I am currently on an assignment that requires us to create a library system. We are required to implement a book search function whereby the user will enter just a single word and we will be able to output the result based on that.
For example, in MySQL database, for Books, I have 5 attributes, namely title, authors, ISBN, publisher and publication year.
I would have to write my queries in PyMySQL in a way that when the user enter one word of an author's name let's say "George", it will output all the books with the author being "George".
So it can be "George Orwell" or "George Alex" etc. All the names in the db are in full. So I am not too sure how to filter the db based on that one word, and output the result.
Looking forward to your help! Thank you. Sorry I cannot post images since I am a new user...
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
