diff --git a/cli/worblehat.py b/cli/worblehat.py index fd45de0..c46a9ba 100644 --- a/cli/worblehat.py +++ b/cli/worblehat.py @@ -226,7 +226,11 @@ def list_cmd(connection, what): fun(connection) def search_book(connection, search_strings, search_description=False): - pass + c = connection.cursor() + c.execute('SELECT * FROM book WHERE book.title LIKE %(search_strings)s', {"search_strings": '%' + search_strings[0] + '%'}) + for i in xrange(c.rowcount): + cat = fetchone_dict(c) + print cat['title'] def search_person(connection, search_strings): pass